Interface IdBatchAdminSession
- All Superinterfaces:
AutoCloseable, Closeable, IdAdminSession, OsidSession, OsidSession
This session creates Ids in bulk. The data for create is
provided by the consumer via the form object. OsidForms are
requested for each create or update and may not be reused.
Create operations differ in their usage. To create an Id , an
IdForm is requested using getIdFormsForCreate() specifying
the desired reference, resource, and record Types or none if no
record Types are needed. Each of the returned IdForms will
indicate that it is to be used with a create operation and can be used to
examine metdata or validate data prior to creation. Once an IdForm
is submiited to a create operation, it cannot be reused with another
create operation unless the first operation was unsuccessful. Each
IdForm corresponds to an attempted transaction.
The IdForms returned from getIdFormsForCreate() may be
linked to the originating request through the peer Ids of the
IdForm .
Once a batch of IdForms are submitted for create, a
CreateResponse is returned for each IdForm , although the
ordering is not defined. Only errors that pertain to the entire create
operation are returned from createIds() , errors specific to an
individual IdForm are indicated in the corresponding
CreateResponse . CreateResponses may be linked to the originating
IdForm through the IdForm Id .
-
Method Summary
Modifier and TypeMethodDescriptionaliasIds(AliasRequestList aliasRequests) Makes a set ofIdsknown to this service equivalent such that for each primary and equivalentIdin the given array, calls toIdLookupSession.getId(equivalentId)return theprimaryId.createIds(IdBatchFormList idForms) Creates a new set ofIds.getIdFormsForCreate(long number) Gets theIdforms for creating new Ids.Methods inherited from interface IdAdminSession
aliasId, canAliasIds, canCreateIds, createId, getIdFormForCreate, removeAliasModifier and TypeMethodDescriptionvoidMakes twoIdsequivalent.booleanTests if this user can aliasIds.booleanTests if this user can createIds.Creates a newId.Gets theIdform for creating new Ids.voidremoveAlias(Id id, Id aliasId) Removes an alias.Methods inherited from interface OsidSession
closeMethods inherited from interface OsidSession
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactionsModifier and TypeMethodDescriptionGets the agent authenticated to this session.Gets theIdof the agent authenticated to this session.Gets the rate of the service clock.getDate()Gets the service date which may be the current date or the effective date in which this session exists.Gets the effective agent in use by this session.Gets theIdof the effective agent in use by this session.Gets theDisplayTextformatTypepreference in effect for this session.Gets the locale indicating the localization preferences in effect for this session.booleanTests if an agent is authenticated to this session.Starts a new transaction for this sesson.booleanTests for the availability of transactions.
-
Method Details
-
getIdFormsForCreate
IdBatchFormList getIdFormsForCreate(long number) throws OperationFailedException, PermissionDeniedException Gets theIdforms for creating new Ids. A new form should be requested for each create transaction.- Parameters:
number- ther number of forms to request- Returns:
- the
Idforms - Throws:
OperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
createIds
CreateResponseList createIds(IdBatchFormList idForms) throws OperationFailedException, PermissionDeniedException Creates a new set ofIds. This method returns an error if the entire operation fails. Otherwise, the status of an individual create operation is indicated in theBatchCreateResponse.- Parameters:
idForms- theIdforms- Returns:
- the create responses
- Throws:
NullArgumentException-idFormsisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
aliasIds
AliasResponseList aliasIds(AliasRequestList aliasRequests) throws OperationFailedException, PermissionDeniedException Makes a set ofIdsknown to this service equivalent such that for each primary and equivalentIdin the given array, calls toIdLookupSession.getId(equivalentId)return theprimaryId.- Parameters:
aliasRequests- the alias requests- Returns:
- the alias responses
- Throws:
NullArgumentException-aliasRequestsisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-