Class SearchResource
java.lang.Object
com.atlassian.crowd.plugin.rest.service.resource.AbstractResource
com.atlassian.crowd.plugin.rest.service.resource.usermanagement.SearchResource
@Path("search")
@Consumes({"application/xml","application/json"})
@Produces({"application/xml","application/json"})
public class SearchResource
extends AbstractResource
Search resource.
-
Field Summary
Fields inherited from class com.atlassian.crowd.plugin.rest.service.resource.AbstractResource
request, uriInfo
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionjavax.ws.rs.core.Response
search
(String entityType, int maxResults, int startIndex, SearchRestrictionEntity searchRestriction) Searches for entities of entity-type (either 'user' or 'group') satisfying the given search restriction.javax.ws.rs.core.Response
searchByCql
(String entityType, int maxResults, int startIndex, String cqlSearchRestriction) Searches for entities of entity-type (either 'user' or 'group') with the specified search restriction (as Crowd Query Language).Methods inherited from class com.atlassian.crowd.plugin.rest.service.resource.AbstractResource
getApplicationName, getBaseUri, setApplicationName, setRequest, setUriInfo
-
Constructor Details
-
SearchResource
-
-
Method Details
-
search
@POST public javax.ws.rs.core.Response search(@QueryParam("entity-type") String entityType, @QueryParam("max-results") @DefaultValue("1000") int maxResults, @QueryParam("start-index") @DefaultValue("0") int startIndex, SearchRestrictionEntity searchRestriction) throws DirectoryNotFoundException, OperationFailedException Searches for entities of entity-type (either 'user' or 'group') satisfying the given search restriction.- Parameters:
entityType
- type of the entity to searchmaxResults
- maximum number of results returnedstartIndex
- starting index of the resultssearchRestriction
- restriction entities must satisfy- Throws:
DirectoryNotFoundException
OperationFailedException
-
searchByCql
@GET public javax.ws.rs.core.Response searchByCql(@QueryParam("entity-type") String entityType, @DefaultValue("1000") @QueryParam("max-results") int maxResults, @DefaultValue("0") @QueryParam("start-index") int startIndex, @DefaultValue("") @QueryParam("restriction") String cqlSearchRestriction) throws DirectoryNotFoundException, OperationFailedException Searches for entities of entity-type (either 'user' or 'group') with the specified search restriction (as Crowd Query Language).- Parameters:
entityType
- type of the entity to searchmaxResults
- maximum number of results returnedstartIndex
- starting index of the resultscqlSearchRestriction
- restriction entities must satisfy in the Crowd Query Language- Throws:
DirectoryNotFoundException
OperationFailedException
-