Class SearchRequestBuilder
- java.lang.Object
-
- com.unboundid.scim2.client.requests.RequestBuilder<T>
-
- com.unboundid.scim2.client.requests.ResourceReturningRequestBuilder<SearchRequestBuilder>
-
- com.unboundid.scim2.client.requests.SearchRequestBuilder
-
public final class SearchRequestBuilder extends ResourceReturningRequestBuilder<SearchRequestBuilder>
A builder for SCIM search requests.
-
-
Field Summary
-
Fields inherited from class com.unboundid.scim2.client.requests.ResourceReturningRequestBuilder
attributes, excluded
-
Fields inherited from class com.unboundid.scim2.client.requests.RequestBuilder
headers, queryParams
-
-
Constructor Summary
Constructors Constructor Description SearchRequestBuilder(javax.ws.rs.client.WebTarget target)Create a new search request builder.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SearchRequestBuilderfilter(String filter)Request filtering of resources.<T> voidinvoke(SearchResultHandler<T> resultHandler, Class<T> cls)Invoke the SCIM retrieve request using GET.<T> com.unboundid.scim2.common.messages.ListResponse<T>invoke(Class<T> cls)Invoke the SCIM retrieve request using GET.<T> voidinvokePost(SearchResultHandler<T> resultHandler, Class<T> cls)Invoke the SCIM retrieve request using POST.<T extends com.unboundid.scim2.common.ScimResource>
com.unboundid.scim2.common.messages.ListResponse<T>invokePost(Class<T> cls)Invoke the SCIM retrieve request using POST.SearchRequestBuilderpage(int startIndex, int count)Request pagination of resources.SearchRequestBuildersort(String sortBy, com.unboundid.scim2.common.messages.SortOrder sortOrder)Request sorting of resources.-
Methods inherited from class com.unboundid.scim2.client.requests.ResourceReturningRequestBuilder
attributes, excludedAttributes
-
Methods inherited from class com.unboundid.scim2.client.requests.RequestBuilder
accept, contentType, getAccept, getContentType, header, queryParam, target
-
-
-
-
Constructor Detail
-
SearchRequestBuilder
public SearchRequestBuilder(javax.ws.rs.client.WebTarget target)
Create a new search request builder.- Parameters:
target- The WebTarget to search.
-
-
Method Detail
-
filter
public SearchRequestBuilder filter(String filter)
Request filtering of resources.- Parameters:
filter- the filter string used to request a subset of resources.- Returns:
- This builder.
-
sort
public SearchRequestBuilder sort(String sortBy, com.unboundid.scim2.common.messages.SortOrder sortOrder)
Request sorting of resources.- Parameters:
sortBy- the string indicating the attribute whose value shall be used to order the returned responses.sortOrder- the order in which the sortBy parameter is applied.- Returns:
- This builder.
-
page
public SearchRequestBuilder page(int startIndex, int count)
Request pagination of resources.- Parameters:
startIndex- the 1-based index of the first query result.count- the desired maximum number of query results per page.- Returns:
- This builder.
-
invoke
public <T> com.unboundid.scim2.common.messages.ListResponse<T> invoke(Class<T> cls) throws com.unboundid.scim2.common.exceptions.ScimException
Invoke the SCIM retrieve request using GET.- Type Parameters:
T- The type of objects to return.- Parameters:
cls- The Java class object used to determine the type to return.- Returns:
- The ListResponse containing the search results.
- Throws:
com.unboundid.scim2.common.exceptions.ScimException- If an error occurred.
-
invoke
public <T> void invoke(SearchResultHandler<T> resultHandler, Class<T> cls) throws com.unboundid.scim2.common.exceptions.ScimException
Invoke the SCIM retrieve request using GET.- Type Parameters:
T- The type of objects to return.- Parameters:
resultHandler- The search result handler that should be used to process the resources.cls- The Java class object used to determine the type to return.- Throws:
com.unboundid.scim2.common.exceptions.ScimException- If an error occurred.
-
invokePost
public <T extends com.unboundid.scim2.common.ScimResource> com.unboundid.scim2.common.messages.ListResponse<T> invokePost(Class<T> cls) throws com.unboundid.scim2.common.exceptions.ScimException
Invoke the SCIM retrieve request using POST.- Type Parameters:
T- The type of objects to return.- Parameters:
cls- The Java class object used to determine the type to return.- Returns:
- The ListResponse containing the search results.
- Throws:
com.unboundid.scim2.common.exceptions.ScimException- If an error occurred.
-
invokePost
public <T> void invokePost(SearchResultHandler<T> resultHandler, Class<T> cls) throws com.unboundid.scim2.common.exceptions.ScimException
Invoke the SCIM retrieve request using POST.- Type Parameters:
T- The type of objects to return.- Parameters:
resultHandler- The search result handler that should be used to process the resources.cls- The Java class object used to determine the type to return.- Throws:
com.unboundid.scim2.common.exceptions.ScimException- If an error occurred.
-
-