org.exoplatform.poll.service.ws
Class PollWebservice
java.lang.Object
org.exoplatform.poll.service.ws.PollWebservice
- All Implemented Interfaces:
- org.exoplatform.services.rest.resource.ResourceContainer
public class PollWebservice
- extends Object
- implements org.exoplatform.services.rest.resource.ResourceContainer
Handles REST request to process Poll.
|
Method Summary |
javax.ws.rs.core.Response |
viewPoll(String pollId,
javax.ws.rs.core.SecurityContext sc,
javax.ws.rs.core.UriInfo uriInfo)
Views a poll by its Id. |
javax.ws.rs.core.Response |
votePoll(String pollId,
String indexVote,
javax.ws.rs.core.SecurityContext sc,
javax.ws.rs.core.UriInfo uriInfo)
Votes for a poll by its Id. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
APP_TYPE
public static final String APP_TYPE
PollWebservice
public PollWebservice()
viewPoll
public javax.ws.rs.core.Response viewPoll(String pollId,
@Context
javax.ws.rs.core.SecurityContext sc,
@Context
javax.ws.rs.core.UriInfo uriInfo)
throws Exception
- Views a poll by its Id.
- Parameters:
pollId - The poll Id to view.sc - The security context which gets the information of the current user.uriInfo - The URI information which gets the information of the current user.
- Returns:
- The response is JSON data.
- Throws:
Exception
votePoll
public javax.ws.rs.core.Response votePoll(String pollId,
String indexVote,
@Context
javax.ws.rs.core.SecurityContext sc,
@Context
javax.ws.rs.core.UriInfo uriInfo)
throws Exception
- Votes for a poll by its Id.
- Parameters:
pollId - The poll Id to vote.indexVote - The vote indexes selected by the current user.sc - The security context which gets the information of the current user.uriInfo - The URI information which gets the information of the current user.
- Returns:
- The response is JSON data.
- Throws:
Exception
Copyright © 2003-2013 eXo Platform SAS. All Rights Reserved.