public class CeleAPI
extends java.lang.Object
| Constructor and Description |
|---|
CeleAPI() |
| Modifier and Type | Method and Description |
|---|---|
HolidayBean |
addHoliday(HolidayBean holiday)
Add a holiday to datastore
|
void |
deleteHoliday(java.lang.String id)
Delete a holiday element from datastore
|
YelpBean |
getYelpSuggestions(java.lang.String searchDate,
double currentLongitude,
double currentLatitude)
Calls the Yelp API to return the requested data
|
com.google.api.server.spi.response.CollectionResponse<HolidayBean> |
listHolidays(java.lang.Integer count)
Return certain holiday data from the datastore
|
HolidayBean |
updateHoliday(HolidayBean holiday)
Update an existing holiday
|
public YelpBean getYelpSuggestions(@Named(value="searchDate") java.lang.String searchDate, @Named(value="currentLongitude") double currentLongitude, @Named(value="currentLatitude") double currentLatitude) throws java.io.IOException, com.google.api.server.spi.response.ConflictException
searchKeyword - Relevant search informationcurrentLongitude - GPS longitudecurrentLatitude - GPS lattitudejava.io.IOExceptioncom.google.api.server.spi.response.ConflictExceptionpublic HolidayBean addHoliday(HolidayBean holiday) throws com.google.api.server.spi.response.ConflictException
holiday - Object with holiday information to addcom.google.api.server.spi.response.ConflictExceptionpublic HolidayBean updateHoliday(HolidayBean holiday) throws com.google.api.server.spi.response.NotFoundException
holiday - Object with new information to updatecom.google.api.server.spi.response.NotFoundExceptionpublic void deleteHoliday(@Named(value="id")
java.lang.String id)
throws com.google.api.server.spi.response.NotFoundException
id - Identifier for holiday to deletecom.google.api.server.spi.response.NotFoundExceptionpublic com.google.api.server.spi.response.CollectionResponse<HolidayBean> listHolidays(@Named(value="count") java.lang.Integer count)
count - number of holidays to return