Class SpaceRestResourcesV1
- java.lang.Object
-
- org.exoplatform.social.rest.impl.space.SpaceRestResourcesV1
-
- All Implemented Interfaces:
org.exoplatform.services.rest.resource.ResourceContainer,SocialRest,SpaceRestResources
public class SpaceRestResourcesV1 extends Object implements SpaceRestResources
-
-
Constructor Summary
Constructors Constructor Description SpaceRestResourcesV1(ActivityRestResourcesV1 activityRestResourcesV1, org.exoplatform.social.core.space.spi.SpaceService spaceService, org.exoplatform.social.core.manager.IdentityManager identityManager, org.exoplatform.upload.UploadService uploadService)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description javax.ws.rs.core.ResponseaddSpaceApplication(String spaceId, String appId)javax.ws.rs.core.ResponseaddSpaceApplication(org.exoplatform.application.registry.Application application)javax.ws.rs.core.ResponsecreateSpace(javax.ws.rs.core.UriInfo uriInfo, String expand, SpaceEntity model)Process to create a new spacejavax.ws.rs.core.ResponsedeclineExternalInvitations(javax.ws.rs.core.UriInfo uriInfo, String invitationId)javax.ws.rs.core.ResponsedeleteSpaceApplication(String applicationName)javax.ws.rs.core.ResponsedeleteSpaceApplication(String spaceId, String appId)javax.ws.rs.core.ResponsedeleteSpaceById(javax.ws.rs.core.UriInfo uriInfo, String id, String expand)Process to delete a space by idjavax.ws.rs.core.ResponsegetSpaceActivitiesById(javax.ws.rs.core.UriInfo uriInfo, String id, int offset, int limit, String before, String after, boolean returnSize, String expand)Deprecated.javax.ws.rs.core.ResponsegetSpaceApplications(String spaceId)javax.ws.rs.core.ResponsegetSpaceApplicationsChoices()javax.ws.rs.core.ResponsegetSpaceAvatarById(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.Request request, String lastModified, String id, String token)javax.ws.rs.core.ResponsegetSpaceBannerById(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.Request request, String lastModified, String id, String token)javax.ws.rs.core.ResponsegetSpaceByDisplayName(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.Request request, String displayName, String expand)Process to return a space by display namejavax.ws.rs.core.ResponsegetSpaceById(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.Request request, String id, String expand)Process to return a space by idjavax.ws.rs.core.ResponsegetSpaceByPrettyName(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.Request request, String prettyName, String expand)Process to return a space by pretty namejavax.ws.rs.core.ResponsegetSpaceExternalInvitations(javax.ws.rs.core.UriInfo uriInfo, String id)javax.ws.rs.core.ResponsegetSpaceMembers(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.Request request, String id, String q, String role, int offset, int limit, boolean returnSize, String expand)Process to return a space by idjavax.ws.rs.core.ResponsegetSpaceNavigations(javax.servlet.http.HttpServletRequest request, String spaceId)javax.ws.rs.core.ResponsegetSpaces(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.Request request, String q, String filterType, int offset, int limit, String sort, String order, boolean returnSize, String expand)Process to return a list of space in json formatjavax.ws.rs.core.ResponseisSpaceMember(javax.ws.rs.core.UriInfo uriInfo, String id, String userId)Checks if is the given userId is a space member.javax.ws.rs.core.ResponsemoveSpaceApplicationOrder(String spaceId, String appId, int transition)javax.ws.rs.core.ResponsepostActivityOnSpace(javax.ws.rs.core.UriInfo uriInfo, String id, String expand, ActivityEntity model)Deprecated.javax.ws.rs.core.ResponseupdateSpaceById(javax.ws.rs.core.UriInfo uriInfo, String id, String expand, SpaceEntity model)Process to update a space by id
-
-
-
Constructor Detail
-
SpaceRestResourcesV1
public SpaceRestResourcesV1(ActivityRestResourcesV1 activityRestResourcesV1, org.exoplatform.social.core.space.spi.SpaceService spaceService, org.exoplatform.social.core.manager.IdentityManager identityManager, org.exoplatform.upload.UploadService uploadService)
-
-
Method Detail
-
getSpaces
@RolesAllowed("users") public javax.ws.rs.core.Response getSpaces(@Context javax.ws.rs.core.UriInfo uriInfo, @Context javax.ws.rs.core.Request request, String q, String filterType, int offset, int limit, String sort, String order, boolean returnSize, String expand) throws ExceptionProcess to return a list of space in json format- Specified by:
getSpacesin interfaceSpaceRestResources- Returns:
- Throws:
Exception
-
createSpace
@RolesAllowed("users") public javax.ws.rs.core.Response createSpace(@Context javax.ws.rs.core.UriInfo uriInfo, String expand, SpaceEntity model) throws ExceptionProcess to create a new space- Specified by:
createSpacein interfaceSpaceRestResources- Returns:
- Throws:
Exception
-
getSpaceById
@RolesAllowed("users") public javax.ws.rs.core.Response getSpaceById(@Context javax.ws.rs.core.UriInfo uriInfo, @Context javax.ws.rs.core.Request request, String id, String expand) throws ExceptionProcess to return a space by id- Specified by:
getSpaceByIdin interfaceSpaceRestResources- Returns:
- Throws:
Exception
-
getSpaceByPrettyName
@RolesAllowed("users") public javax.ws.rs.core.Response getSpaceByPrettyName(@Context javax.ws.rs.core.UriInfo uriInfo, @Context javax.ws.rs.core.Request request, String prettyName, String expand) throws ExceptionProcess to return a space by pretty name- Specified by:
getSpaceByPrettyNamein interfaceSpaceRestResources- Returns:
- Throws:
Exception
-
getSpaceByDisplayName
@RolesAllowed("users") public javax.ws.rs.core.Response getSpaceByDisplayName(@Context javax.ws.rs.core.UriInfo uriInfo, @Context javax.ws.rs.core.Request request, String displayName, String expand) throws ExceptionProcess to return a space by display name- Specified by:
getSpaceByDisplayNamein interfaceSpaceRestResources- Returns:
- Throws:
Exception
-
getSpaceAvatarById
public javax.ws.rs.core.Response getSpaceAvatarById(@Context javax.ws.rs.core.UriInfo uriInfo, @Context javax.ws.rs.core.Request request, String lastModified, String id, String token) throws IOException- Throws:
IOException
-
getSpaceBannerById
public javax.ws.rs.core.Response getSpaceBannerById(@Context javax.ws.rs.core.UriInfo uriInfo, @Context javax.ws.rs.core.Request request, String lastModified, String id, String token) throws IOException- Throws:
IOException
-
updateSpaceById
@RolesAllowed("users") public javax.ws.rs.core.Response updateSpaceById(@Context javax.ws.rs.core.UriInfo uriInfo, String id, String expand, SpaceEntity model) throws ExceptionProcess to update a space by id- Specified by:
updateSpaceByIdin interfaceSpaceRestResources- Returns:
- Throws:
Exception
-
deleteSpaceById
@RolesAllowed("users") public javax.ws.rs.core.Response deleteSpaceById(@Context javax.ws.rs.core.UriInfo uriInfo, String id, String expand) throws ExceptionProcess to delete a space by id- Specified by:
deleteSpaceByIdin interfaceSpaceRestResources- Returns:
- Throws:
Exception
-
getSpaceMembers
@RolesAllowed("users") public javax.ws.rs.core.Response getSpaceMembers(@Context javax.ws.rs.core.UriInfo uriInfo, @Context javax.ws.rs.core.Request request, String id, String q, String role, int offset, int limit, boolean returnSize, String expand) throws ExceptionProcess to return a space by id- Specified by:
getSpaceMembersin interfaceSpaceRestResources- Returns:
- Throws:
Exception
-
isSpaceMember
@RolesAllowed("users") public javax.ws.rs.core.Response isSpaceMember(@Context javax.ws.rs.core.UriInfo uriInfo, String id, String userId)Checks if is the given userId is a space member.- Parameters:
uriInfo- the uri infoid- the space iduserId- the user id- Returns:
- the response
-
getSpaceNavigations
@RolesAllowed("users") public javax.ws.rs.core.Response getSpaceNavigations(@Context javax.servlet.http.HttpServletRequest request, String spaceId)
-
getSpaceApplicationsChoices
@RolesAllowed("users") public javax.ws.rs.core.Response getSpaceApplicationsChoices()
-
addSpaceApplication
@RolesAllowed("administrators") public javax.ws.rs.core.Response addSpaceApplication(org.exoplatform.application.registry.Application application)
-
deleteSpaceApplication
@RolesAllowed("administrators") public javax.ws.rs.core.Response deleteSpaceApplication(String applicationName)
-
getSpaceApplications
@RolesAllowed("users") public javax.ws.rs.core.Response getSpaceApplications(String spaceId)
-
deleteSpaceApplication
@RolesAllowed("users") public javax.ws.rs.core.Response deleteSpaceApplication(String spaceId, String appId)
-
addSpaceApplication
@RolesAllowed("users") public javax.ws.rs.core.Response addSpaceApplication(String spaceId, String appId)
-
moveSpaceApplicationOrder
@RolesAllowed("users") public javax.ws.rs.core.Response moveSpaceApplicationOrder(String spaceId, String appId, int transition)
-
getSpaceActivitiesById
@RolesAllowed("users") @Deprecated public javax.ws.rs.core.Response getSpaceActivitiesById(@Context javax.ws.rs.core.UriInfo uriInfo, String id, int offset, int limit, String before, String after, boolean returnSize, String expand) throws ExceptionDeprecated.- Throws:
Exception
-
postActivityOnSpace
@RolesAllowed("users") @Deprecated public javax.ws.rs.core.Response postActivityOnSpace(@Context javax.ws.rs.core.UriInfo uriInfo, String id, String expand, ActivityEntity model) throws ExceptionDeprecated.- Throws:
Exception
-
getSpaceExternalInvitations
@RolesAllowed("users") public javax.ws.rs.core.Response getSpaceExternalInvitations(@Context javax.ws.rs.core.UriInfo uriInfo, String id)
-
declineExternalInvitations
@RolesAllowed("users") public javax.ws.rs.core.Response declineExternalInvitations(@Context javax.ws.rs.core.UriInfo uriInfo, String invitationId)
-
-