OSID Logo
OSID Specifications
inquiry batch package
Version 3.0.0
Release Candidate Preview
Interfaceosid.inquiry.batch.AuditBatchAdminSession
Implementsosid.inquiry.AuditAdminSession
Description

This session creates and deletes Audits 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.

To create an Audit, an AuditForm is requested using getAuditFormsForCreate() specifying the desired record Types or none if no record Types are needed. Each of the returned AuditForms 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 AuditForm is submiited to a create operation, it cannot be reused with another create operation unless the first operation was unsuccessful. Each AuditForms corresponds to an attempted transaction.

The AuditForms returned from getSubtaskFormsForCreate() may be linked to the originating request through the peer Ids of the AuditForm. In the case where there may be duplicates, any AuditForm of the same peer Ids may be used for a create operation.

Once a batch of AuditForms are submitted for create, a CreateResponse is returned for each AuditForms, although the ordering is not defined. Only errors that pertain to the entire create operation are returned from createSubtasks(), errors specific to an individual AuditForm are indicated in the corresponding CreateResponse. CreateResponses may be linked to the originating AuditForm through the AuditForm Id .

MethodgetAuditFormsForCreate
Description

Gets the audit forms for creating a bunch of new audtits.

Parameterscardinalnnumber of forms to retrieve
osid.type.Type[]auditRecordTypesarray of audtit record types to be included in each create operation or an empty list if none
Returnosid.inquiry.batch.AuditBatchFormListthe audit forms
ErrorsNULL_ARGUMENT auditRecordTypes is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTEDunable to request forms with given record types
CompliancemandatoryThis method must be implemented.
MethodcreateAudits
Description

Creates a new set of Audits. This method returns an error if the entire operation fails. Otherwise, the status of an individual create operation is indicated in the BatchCreateResponse .

Parametersosid.inquiry.batch.AuditBatchFormListauditFormsthe audit forms
Returnosid.transaction.batch.CreateResponseListthe create responses
ErrorsNULL_ARGUMENT auditForms is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetAuditFormsForUpdate
Description

Gets the audit forms for updating an existing set of audits. A new audit form should be requested for each update transaction.

Parametersosid.id.IdListauditIdsthe Ids of the Audits
Returnosid.inquiry.batch.AuditBatchFormListthe audit forms
ErrorsNOT_FOUNDan auditId is not found
NULL_ARGUMENT auditIds is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodupdateAudits
Description

Updates existing auditis. This method returns an error if the entire operation fails. Otherwise, the status of an individual update operation is indicated in the BatchCreateResponse .

Parametersosid.inquiry.batch.AuditBatchFormListauditFormsthe form containing the elements to be updated
Returnosid.transaction.batch.UpdateResponseListthe update responses
ErrorsNULL_ARGUMENT auditForms is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethoddeleteAllAudits
Description

Deletes all Audits in this Inquest.

Returnosid.transaction.batch.DeleteResponseListthe delete responses
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodaliasAudits
Description

Adds an Id to an Audit for the purpose of creating compatibility. The primary Id of the Audit is determined by the provider. The new Id is an alias to the primary Id. If the alias is a pointer to another audit, it is reassigned to the given audit Id.

Parametersosid.transaction.batch.AliasRequestListaliasRequeststhe alias requests
Returnosid.transaction.batch.AliasResponseListthe alias responses
ErrorsNULL_ARGUMENT aliasRequests is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.