com.unboundid.scim.marshal
Interface StreamMarshaller

All Known Implementing Classes:
JsonStreamMarshaller, XmlStreamMarshaller

public interface StreamMarshaller

This interface provides methods that may be used to write a stream of SCIM objects to an external representation. There are stream marshaller implementations for XML and JSON. Stream marshaller implementations are not required to be thread-safe.


Method Summary
 void bulkMarshal(int failOnErrors, List<BulkOperation> operations)
          Write the content of a SCIM bulk operation request or response.
 void close()
          Close the marshaller.
 void marshal(BaseResource resource)
          Write a SCIM object.
 void marshal(Resources<? extends BaseResource> response)
          Write a SCIM query response.
 void marshal(SCIMException response)
          Write a SCIM error response.
 void writeBulkFinish()
          Write the end of a bulk request or response.
 void writeBulkOperation(BulkOperation o)
          Write a bulk operation to a bulk request or response.
 void writeBulkStart(int failOnErrors, Set<String> schemaURIs)
          Write the start of a bulk request or response.
 

Method Detail

marshal

void marshal(BaseResource resource)
             throws SCIMException
Write a SCIM object.

Parameters:
resource - The SCIM resource to be written.
Throws:
SCIMException - If the data could not be written.

marshal

void marshal(Resources<? extends BaseResource> response)
             throws SCIMException
Write a SCIM query response.

Parameters:
response - The SCIM response to be written.
Throws:
SCIMException - If the data could not be written.

marshal

void marshal(SCIMException response)
             throws SCIMException
Write a SCIM error response.

Parameters:
response - The SCIM response to be written.
Throws:
SCIMException - If the data could not be written.

bulkMarshal

void bulkMarshal(int failOnErrors,
                 List<BulkOperation> operations)
                 throws SCIMException
Write the content of a SCIM bulk operation request or response.

Parameters:
failOnErrors - The value of failOnErrors, or -1 to not provide a value.
operations - The bulk operations to include in the content.
Throws:
SCIMException - If the data could not be written.

writeBulkStart

void writeBulkStart(int failOnErrors,
                    Set<String> schemaURIs)
                    throws SCIMException
Write the start of a bulk request or response.

Parameters:
failOnErrors - The value of failOnErrors, or -1 to not provide a value.
schemaURIs - The set of schema URIs used by the bulk request or response.
Throws:
SCIMException - If the data could not be written.

writeBulkOperation

void writeBulkOperation(BulkOperation o)
                        throws SCIMException
Write a bulk operation to a bulk request or response.

Parameters:
o - The bulk operation to write.
Throws:
SCIMException - If the data could not be written.

writeBulkFinish

void writeBulkFinish()
                     throws SCIMException
Write the end of a bulk request or response.

Throws:
SCIMException - If the data could not be written.

close

void close()
           throws SCIMException
Close the marshaller.

Throws:
SCIMException - If the data could not be written.


Copyright © 2011-2012 UnboundID. All Rights Reserved.