Class FavoritesRest
- java.lang.Object
-
- fr.paris.lutece.plugins.mydashboard.modules.favorites.rest.rs.FavoritesRest
-
@Path("/rest/favorites-api") public class FavoritesRest extends java.lang.ObjectFavoritesRest
-
-
Constructor Summary
Constructors Constructor Description FavoritesRest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.ws.rs.core.ResponseaddFavorite(java.lang.String strFavoriteJson, java.lang.String strApiKey)javax.ws.rs.core.ResponsegetAllFavorites(javax.servlet.http.HttpServletRequest request)Get all favoritesjavax.ws.rs.core.ResponsegetFavorites(javax.servlet.http.HttpServletRequest request)Get last favoritesjavax.ws.rs.core.ResponseremoveFavorite(java.lang.Integer id, java.lang.String strApiKey)
-
-
-
Method Detail
-
getFavorites
@GET @Path("/lastFavorites") @Produces("application/json") public javax.ws.rs.core.Response getFavorites(@Context javax.servlet.http.HttpServletRequest request)Get last favorites- Parameters:
request-nNbFavoritesToShow-- Returns:
- Json
-
getAllFavorites
@GET @Path("/allFavorites") @Consumes("application/json") @Produces("application/json") public javax.ws.rs.core.Response getAllFavorites(@Context javax.servlet.http.HttpServletRequest request)Get all favorites- Parameters:
request-nNbFavoritesToShow-- Returns:
- Json
-
addFavorite
@POST @Path("/add") @Consumes("application/json") @Produces("application/json") public javax.ws.rs.core.Response addFavorite(java.lang.String strFavoriteJson, @HeaderParam("X-API-KEY") java.lang.String strApiKey)
-
removeFavorite
@DELETE @Path("/remove/{id}") @Produces("application/json") public javax.ws.rs.core.Response removeFavorite(@PathParam("id") java.lang.Integer id, @HeaderParam("X-API-KEY") java.lang.String strApiKey)
-
-