Class ListBuilder<T extends ResourceNode>
- java.lang.Object
-
- de.captaingoldfish.scim.sdk.client.builder.ListBuilder<T>
-
public class ListBuilder<T extends ResourceNode> extends Object
author Pascal Knueppel
created at: 16.12.2019 - 13:00
a builder that can be used to build a list request
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classListBuilder.FilterBuilder<T extends ResourceNode>used to build a filter expressionstatic classListBuilder.GetRequestBuilder<T extends ResourceNode>a request builder that builds the list-request as a http-get requeststatic classListBuilder.ListServerResponse<T extends ResourceNode>overrides the translation of the returned resource from the serverstatic classListBuilder.PostRequestBuilder<T extends ResourceNode>a request builder that builds the list-request as a http-post request
-
Constructor Summary
Constructors Constructor Description ListBuilder(String fullUrl, Class<T> responseEntityType, ScimHttpClient scimHttpClient)if the resource should be retrieved by using the fully qualified urlListBuilder(String baseUrl, String endpoint, Class<T> responseEntityType, ScimHttpClient scimHttpClient)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ListBuilder<T>attributes(String... attributeNames)adds the attributes that should be returned by the service providerListBuilder<T>count(int count)sets the count parameter for the maximum number of entries that should be returnedListBuilder<T>custom(String attributeName, String attribute)adds additional custom parameters to the request that are unknown by the SCIM specificationListBuilder<T>excludedAttributes(String... attributeNames)adds the excluded attributes that should not be returned by the service providerListBuilder.FilterBuilder<T>filter(boolean openParanthesis, String attributeName, Comparator comparator, String value)creates a new filter-builder that can be used to create filter expressionsListBuilder<T>filter(String filter)sets the given filter as attributeListBuilder.FilterBuilder<T>filter(String attributeName, Comparator comparator, String value)creates a new filter-builder that can be used to create filter expressionsListBuilder.GetRequestBuilder<T>get()list requests can be either send with a get-request or a post requestprotected Map<String,String>getRequestParameters()the parameters that will be used for the list requestListBuilder.PostRequestBuilder<T>post()list requests can be either send with a get-request or a post requestListBuilder<T>sortBy(String sortBy)sets the attribute name that should be used for sorting the entriesListBuilder<T>sortOrder(SortOrder sortOrder)sets the sorting order of the resourcesListBuilder<T>startIndex(long startIndex)sets the startIndex parameter for the first entry that should be returned
-
-
-
Constructor Detail
-
ListBuilder
public ListBuilder(String fullUrl, Class<T> responseEntityType, ScimHttpClient scimHttpClient)
if the resource should be retrieved by using the fully qualified url- Parameters:
fullUrl- the fully qualified url to the required resourceresponseEntityType- the type of the resource that should be returnedscimHttpClient- the http client instance
-
ListBuilder
public ListBuilder(String baseUrl, String endpoint, Class<T> responseEntityType, ScimHttpClient scimHttpClient)
-
-
Method Detail
-
count
public ListBuilder<T> count(int count)
sets the count parameter for the maximum number of entries that should be returned- Parameters:
count- the maximum number of entries that should be returned
-
startIndex
public ListBuilder<T> startIndex(long startIndex)
sets the startIndex parameter for the first entry that should be returned- Parameters:
startIndex- the start index from which the entries should be returned
-
sortBy
public ListBuilder<T> sortBy(String sortBy)
sets the attribute name that should be used for sorting the entries- Parameters:
sortBy- the attribute name that should be used for sorting the entries
-
sortOrder
public ListBuilder<T> sortOrder(SortOrder sortOrder)
sets the sorting order of the resources- Parameters:
sortOrder- the sorting order of the resources
-
attributes
public ListBuilder<T> attributes(String... attributeNames)
adds the attributes that should be returned by the service provider- Parameters:
attributeNames- the names of the attributes that should be returned by the service provider
-
excludedAttributes
public ListBuilder<T> excludedAttributes(String... attributeNames)
adds the excluded attributes that should not be returned by the service provider- Parameters:
attributeNames- the names of the excluded attributes that should not be returned by the service provider
-
filter
public ListBuilder.FilterBuilder<T> filter(String attributeName, Comparator comparator, String value)
creates a new filter-builder that can be used to create filter expressions
-
filter
public ListBuilder.FilterBuilder<T> filter(boolean openParanthesis, String attributeName, Comparator comparator, String value)
creates a new filter-builder that can be used to create filter expressions
-
filter
public ListBuilder<T> filter(String filter)
sets the given filter as attribute
-
custom
public ListBuilder<T> custom(String attributeName, String attribute)
adds additional custom parameters to the request that are unknown by the SCIM specification- Parameters:
attributeName- the name of the attribute to addattribute- the value of the attribute to add
-
get
public ListBuilder.GetRequestBuilder<T> get()
list requests can be either send with a get-request or a post request- Returns:
- a get-request builder
-
post
public ListBuilder.PostRequestBuilder<T> post()
list requests can be either send with a get-request or a post request- Returns:
- a post-request builder
-
-