public interface BankBatchAdminSession extends BankAdminSession
This session creates, updates, and deletes Banks in
bulk. The data for create and update is provided by the consumer via the
form object. OsidForms are requested for each create or
update and may not be reused.
Create and update operations differ in their usage. To create a
Bank, a BankForm is requested using
getBankFormsForCreate() specifying the desired record Types
or none if no record Types are needed. Each of the
returned BankForms 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 a BankForm is submiited to a create
operation, it cannot be reused with another create operation unless the
first operation was unsuccessful. Each BankForm corresponds
to an attempted transaction.
The BankForms returned from
getBankFormsForCreate() may be linked to the originating request
through the peer Ids of the BankForm. In the
case where there may be duplicates, any BankForm of the
same peer Ids may be used for a create operation.
Once a batch of BankForms are submitted for create, a
CreateResponse is returned for each BankForm,
although the ordering is not defined. Only errors that pertain to
the entire create operation are returned from createBanks(),
errors specific to an individual BankForm are
indicated in the corresponding CreateResponse.
CreateResponses may be linked to the originating BankForm
through the BankForm Id .
For updates, BankForms are requested to the Bank
Id that is to be updated using
getBankFormsForUpdate() where the reference Id in
the BankForm may be used to link the request. Similarly,
the BankForm has metadata about the data that can be
updated and it can perform validation before submitting the update. The
BankForm can only be used once for a successful update and
cannot be reused.
Once a batch of BankForms are submitted for update, an
UpdateResponse is returned for each BankForm,
although the ordering is not defined. Only errors that pertain to
the entire update operation are returned from updateBanks(),
errors specific to an individual BankForm are
indicated in the corresponding UpdateResponse.
UpdateResponses may be linked to the originating BankForm
through the BankForm Id.
The delete operations delete Banks in bulk. Bulk delete
operations return the results in DeleteResponses.
| Modifier and Type | Method and Description |
|---|---|
AliasResponseList |
aliasBanks(AliasRequestList aliasRequests)
Adds an
Id to a Bank for the purpose of
creating compatibility. |
CreateResponseList |
createBanks(BankBatchFormList bankForms)
Creates a new set of
Banks. |
DeleteResponseList |
deleteAllBanks()
Deletes all
Banks. |
DeleteResponseList |
deleteBanks(IdList bankIds)
Deletes banks for the given
Ids. |
BankBatchFormList |
getBankFormsForCreate(long number,
Type[] bankRecordTypes)
Gets the bank forms for creating a bunch of new banks.
|
BankBatchFormList |
getBankFormsForUpdate(IdList bankIds)
Gets the bank forms for updating an existing set of banks.
|
UpdateResponseList |
updateBanks(BankBatchFormList bankForms)
Updates existing banks.
|
aliasBank, canCreateBanks, canCreateBankWithRecordTypes, canDeleteBanks, canManageBankAliases, canUpdateBanks, createBank, deleteBank, getBankFormForCreate, getBankFormForUpdate, updateBankgetAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactionscloseBankBatchFormList getBankFormsForCreate(long number, Type[] bankRecordTypes) throws OperationFailedException, PermissionDeniedException
number - the number of forms to retrievebankRecordTypes - array of bank record types to be included in
each create operation or an empty list if noneNullArgumentException - bankRecordTypes
is null OperationFailedException - unable to complete requestPermissionDeniedException - authorization failureUnsupportedException - unable to request forms with
given record typesmandatory - This method must be implemented. CreateResponseList createBanks(BankBatchFormList bankForms) throws OperationFailedException, PermissionDeniedException
Banks. This method returns an
error if the entire operation fails. Otherwise, the status of an
individual create operation is indicated in the
BatchCreateResponse .bankForms - the bank formsNullArgumentException - bankForms is
null OperationFailedException - unable to complete requestPermissionDeniedException - authorization failuremandatory - This method must be implemented. BankBatchFormList getBankFormsForUpdate(IdList bankIds) throws NotFoundException, OperationFailedException, PermissionDeniedException
bankIds - the Ids of the Bank NotFoundException - a bankId is not
foundNullArgumentException - bankIds is
null OperationFailedException - unable to complete requestPermissionDeniedException - authorization failuremandatory - This method must be implemented. UpdateResponseList updateBanks(BankBatchFormList bankForms) throws OperationFailedException, PermissionDeniedException
BatchCreateResponse .bankForms - the form containing the elements to be updatedNullArgumentException - bankForms is
null OperationFailedException - unable to complete requestPermissionDeniedException - authorization failuremandatory - This method must be implemented. DeleteResponseList deleteAllBanks() throws OperationFailedException, PermissionDeniedException
Banks. OperationFailedException - unable to complete requestPermissionDeniedException - authorization failuremandatory - This method must be implemented. DeleteResponseList deleteBanks(IdList bankIds) throws OperationFailedException, PermissionDeniedException
Ids. bankIds - the Ids of the banks to deleteNullArgumentException - bankIds is
null OperationFailedException - unable to complete requestPermissionDeniedException - authorization failuremandatory - This method must be implemented. AliasResponseList aliasBanks(AliasRequestList aliasRequests) throws OperationFailedException, PermissionDeniedException
Id to a Bank for the purpose of
creating compatibility. The primary Id of the
Bank is determined by the provider. The new Id
is an alias to the primary Id. If the alias is a
pointer to another bank, it is reassigned to the given bank Id.
aliasRequests - the alias requestsNullArgumentException - aliasRequests is
null OperationFailedException - unable to complete requestPermissionDeniedException - authorization failuremandatory - This method must be implemented.