public class SCIMService extends Object
| Constructor and Description |
|---|
SCIMService(URI baseUrl)
Constructs a new SCIMService that uses
java.net.HttpURLConnection for the HTTP layer. |
SCIMService(URI baseUrl,
org.apache.wink.client.ClientConfig clientConfig)
Constructs a new SCIMService that is configured from the provided
org.apache.wink.client.ClientConfig instance. |
SCIMService(URI baseUrl,
OAuthToken oAuthToken)
Constructs a new SCIMService with OAuth authentication support
using the provided credentials.
|
SCIMService(URI baseUrl,
String username,
String password)
Constructs a new SCIMService with basic authentication support
using the provided credentials.
|
| Modifier and Type | Method and Description |
|---|---|
javax.ws.rs.core.MediaType |
getAcceptType()
Retrieves the accept media type that should be used when reading data from
the SCIM service provider.
|
URI |
getBaseURL()
Retrieves the SCIM Service Provider URL.
|
javax.ws.rs.core.MediaType |
getContentType()
Retrieves the content media type that should be used when writing data to
the SCIM service provider.
|
<R extends BaseResource> |
getEndpoint(ResourceDescriptor resourceDescriptor,
ResourceFactory<R> resourceFactory)
Returns a SCIMEndpoint with the current settings that can be used to
invoke CRUD operations.
|
SCIMEndpoint<GroupResource> |
getGroupEndpoint()
Returns a SCIMEndpoint for the Groups endpoint defined in the core schema.
|
ResourceDescriptor |
getResourceDescriptor(String resourceName,
String schema)
Retrieves the ResourceDescriptor for the specified resource from the
SCIM service provider.
|
SCIMEndpoint<ResourceDescriptor> |
getResourceSchemaEndpoint()
Returns a SCIMEndpoint for the Schemas endpoint.
|
ServiceProviderConfig |
getServiceProviderConfig()
Retrieves the Service Provider Config from the SCIM service provider.
|
String |
getUserAgent()
Retrieves the user-agent string that will be used in the HTTP request
headers.
|
SCIMEndpoint<UserResource> |
getUserEndpoint()
Returns a SCIMEndpoint for the Users endpoint defined in the core schema.
|
boolean |
isOverrideDelete()
Whether to override DELETE operations with POST.
|
boolean |
isOverridePatch()
Whether to override PATCH operations with POST.
|
boolean |
isOverridePut()
Whether to override PUT operations with POST.
|
BulkResponse |
processBulkRequest(List<BulkOperation> operations)
Invoke a bulk request.
|
BulkResponse |
processBulkRequest(List<BulkOperation> operations,
int failOnErrors)
Invoke a bulk request.
|
void |
setAcceptType(javax.ws.rs.core.MediaType acceptType)
Sets the accept media type that should be used when reading data from
the SCIM service provider.
|
void |
setContentType(javax.ws.rs.core.MediaType contentType)
Sets the content media type that should be used when writing data to
the SCIM service provider.
|
void |
setOverrideDelete(boolean overrideDelete)
Sets whether to override DELETE operations with POST.
|
void |
setOverridePatch(boolean overridePatch)
Sets whether to override PATCH operations with POST.
|
void |
setOverridePut(boolean overridePut)
Sets whether to override PUT operations with POST.
|
void |
setUserAgent(String userAgent)
Sets the user-agent string to use in the request headers.
|
public SCIMService(URI baseUrl, org.apache.wink.client.ClientConfig clientConfig)
org.apache.wink.client.ClientConfig instance.baseUrl - The SCIM Service Provider URL.clientConfig - The configuration to use.public SCIMService(URI baseUrl)
java.net.HttpURLConnection for the HTTP layer.baseUrl - The SCIM Service Provider URL.public SCIMService(URI baseUrl, OAuthToken oAuthToken)
java.net.HttpURLConnection for the HTTP layer.baseUrl - The SCIM Service Provider URL.oAuthToken - The OAuth token.public SCIMService(URI baseUrl, String username, String password)
java.net.HttpURLConnection for the HTTP layer.baseUrl - The SCIM Service Provider URL.username - The username.password - The password.public <R extends BaseResource> SCIMEndpoint<R> getEndpoint(ResourceDescriptor resourceDescriptor, ResourceFactory<R> resourceFactory)
R - The type of SCIM resource instances.resourceDescriptor - The ResourceDescriptor of the endpoint.resourceFactory - The ResourceFactory that should be used to
create SCIM resource instances.public SCIMEndpoint<UserResource> getUserEndpoint()
public SCIMEndpoint<GroupResource> getGroupEndpoint()
public SCIMEndpoint<ResourceDescriptor> getResourceSchemaEndpoint()
public ResourceDescriptor getResourceDescriptor(String resourceName, String schema) throws SCIMException
resourceName - The name of the resource.schema - The schema URN of the resource or null
to match only based on the name of the resource.null if none are found.SCIMException - If the ResourceDescriptor could not be read.public ServiceProviderConfig getServiceProviderConfig() throws SCIMException
SCIMException - If the Service Provider Config could not be read.public BulkResponse processBulkRequest(List<BulkOperation> operations) throws SCIMException
operations - The operations to be performed.SCIMException - If the request fails.public BulkResponse processBulkRequest(List<BulkOperation> operations, int failOnErrors) throws SCIMException
operations - The operations to be performed.failOnErrors - The number of errors that the service provider will
accept before the operation is terminated and an
error response is returned. A value of -1 indicates
the the service provider will continue to perform
as many operations as possible without regard to
failures.SCIMException - If the request fails.public URI getBaseURL()
public javax.ws.rs.core.MediaType getContentType()
public void setContentType(javax.ws.rs.core.MediaType contentType)
contentType - he content media type that should be used when writing
data to the SCIM service provider.public javax.ws.rs.core.MediaType getAcceptType()
public void setAcceptType(javax.ws.rs.core.MediaType acceptType)
acceptType - The accept media type that should be used when reading
data from the SCIM service provider.public String getUserAgent()
public void setUserAgent(String userAgent)
userAgent - The user-agent string that should be used.public boolean isOverrideDelete()
true to override DELETE operations with POST or
false to use the DELETE method.public void setOverrideDelete(boolean overrideDelete)
overrideDelete - true to override DELETE operations with
POST or false to use the DELETE method.public boolean isOverridePatch()
true to override PATCH operations with POST or
false to use the PATCH method.public void setOverridePatch(boolean overridePatch)
overridePatch - true to override PATCH operations with
POST or false to use the PATCH method.public boolean isOverridePut()
true to override PUT operations with POST or
false to use the PUT method.public void setOverridePut(boolean overridePut)
overridePut - true to override PUT operations with
POST or false to use the PUT method.Copyright © 2011-2013 UnboundID. All Rights Reserved.