Class GamificationRestEndpoint
- java.lang.Object
-
- org.exoplatform.addons.gamification.rest.GamificationRestEndpoint
-
- All Implemented Interfaces:
org.exoplatform.services.rest.resource.ResourceContainer
@RolesAllowed("users") public class GamificationRestEndpoint extends Object implements org.exoplatform.services.rest.resource.ResourceContainer
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classGamificationRestEndpoint.GamificationPoints
-
Constructor Summary
Constructors Constructor Description GamificationRestEndpoint(GamificationService gamificationService, org.exoplatform.social.core.manager.IdentityManager identityManager, DomainService domainService, RuleService ruleService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.ws.rs.core.ResponsegetAllEvents()Return all eventsjavax.ws.rs.core.ResponsegetAllPointsByUserId(String userId, String period)Return all earned points by a userjavax.ws.rs.core.ResponsegetAllPointsByUserIdByDate(String userId, String startDateEntry, String endDateEntry)Return earned points by a user during a given periodjavax.ws.rs.core.ResponsegetDomains()Return enabled domainsjavax.ws.rs.core.ResponsegetLeaderboardByDate(javax.ws.rs.core.UriInfo uriInfo, String earnerType, String startDateEntry, String endDateEntry)
-
-
-
Constructor Detail
-
GamificationRestEndpoint
public GamificationRestEndpoint(GamificationService gamificationService, org.exoplatform.social.core.manager.IdentityManager identityManager, DomainService domainService, RuleService ruleService)
-
-
Method Detail
-
getAllPointsByUserId
@RolesAllowed("users") public javax.ws.rs.core.Response getAllPointsByUserId(String userId, String period)Return all earned points by a user- Parameters:
userId- : user social idperiod- : Period of time- Returns:
- : and object of type GamificationPoints
-
getAllPointsByUserIdByDate
@RolesAllowed("users") public javax.ws.rs.core.Response getAllPointsByUserIdByDate(String userId, String startDateEntry, String endDateEntry)Return earned points by a user during a given period- Parameters:
userId- : user social idstartDateEntry- : Date from when gamification api filter earned pointsendDateEntry- : Date until when gamification api filter eearned points- Returns:
- : and object of type GamificationPoints
-
getLeaderboardByDate
@RolesAllowed("users") public javax.ws.rs.core.Response getLeaderboardByDate(@Context javax.ws.rs.core.UriInfo uriInfo, String earnerType, String startDateEntry, String endDateEntry)
-
getDomains
@RolesAllowed("users") public javax.ws.rs.core.Response getDomains()Return enabled domains- Returns:
- : list of enabled domains
-
getAllEvents
@RolesAllowed("users") public javax.ws.rs.core.Response getAllEvents()Return all events- Returns:
- : list of all events
-
-