OSID Logo
OSID Specifications
grading transform package
Version 3.0.0
Release Candidate Preview
Interfaceosid.grading.transform.GradeSystemTransformAdminSession
Implementsosid.OsidSession
Description

This session creates, updates, and deletes GradeSystemTransforms. 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 GradeSystemTransform, a GradeSystemTransformForm is requested using getGradeSystemTransformFormForCreate() specifying the desired record Types or none if no record Types are needed. The returned GradeSystemTransformForm 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 the GradeSystemTransformForm is submiited to a create operation, it cannot be reused with another create operation unless the first operation was unsuccessful. Each GradeSystemTransformForm corresponds to an attempted transaction.

For updates, GradeSystemTransformForms are requested to the GradeSystemTransformForm Id that is to be updated using getGradeSystemTransformFormForUpdate(). Similarly, the GradeSystemTransformForm has metadata about the data that can be updated and it can perform validation before submitting the update. The GradeSystemTransformForm can only be used once for a successful update and cannot be reused.

The delete operations delete GradeSystemTransforms.

This session includes an Id aliasing mechanism to assign an external Id to an internally assigned Id.

MethodgetGradebookId
Description

Gets the Gradebook Id associated with this session.

Returnosid.id.Idthe Gradebook Id associated with this session
CompliancemandatoryThis method must be implemented.
MethodgetGradebook
Description

Gets the Gradebook associated with this session.

Returnosid.grading.Gradebookthe Gradebook associated with this session
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanCreateGradeSystemTransforms
Description

Tests if this user can create GradeSystemTransforms. A return of true does not guarantee successful authorization. A return of false indicates that it is known creating a GradeSystemTransform will result in a PERMISSION_DENIED. This is intended as a hint to an application that may not wish to offer create operations to unauthorized users.

Returnboolean false if GradeSystemTransform creation is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodcanCreateGradeSystemTransformWithRecordTypes
Description

Tests if this user can create a single GradeSystemTransform using the desired record types. While GradingTransformManager.getGradeSystemTransformRecordTypes() can be used to examine which records are supported, this method tests which record(s) are required for creating a specific GradeSystemTransform. Providing an empty array tests if a GradeSystemTransform can be created with no records.

Parametersosid.type.Type[]gradeSystemTransformRecordTypesarray of grade system transform record types
Returnboolean true if GradeSystemTransform creation using the specified Types is supported, false otherwise
ErrorsNULL_ARGUMENT gradeSystemTransformRecordTypes is null
CompliancemandatoryThis method must be implemented.
MethodgetGradeSystemTransformFormForCreate
Description

Gets the grade system transform form for creating new grade system transforms. A new form should be requested for each create transaction.

Parametersosid.id.IdsourceGradeSystemIdthe Id for the source GradeSystem
osid.id.IdtargetGradeSystemIdthe Id for the source GradeSystem
osid.type.Type[]gradeSystemTransformRecordTypesarray of grade system transform record types
Returnosid.grading.transform.GradeSystemTransformFormthe grade system transform form
ErrorsNOT_FOUND sourceHradeSystemId or targetGradeSystemId not found
NULL_ARGUMENT sourceGradeSystemId, targetGradeSystemId, gradeSystemTransformRecordTypes is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTEDunable to get form for requested record types
CompliancemandatoryThis method must be implemented.
MethodcreateGradeSystemTransform
Description

Creates a new GradeSystemTransform.

Parametersosid.grading.transform.GradeSystemTransformFormgradeSystemTransformFormthe form for this GradeSystemTransform
Returnosid.grading.transform.GradeSystemTransformthe new GradeSystemTransform
ErrorsILLEGAL_STATE gradeSystemTransformForm already used in a create transaction
INVALID_ARGUMENTone or more of the form elements is invalid
NULL_ARGUMENT gradeSystemTransformForm is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTED gradeSystemTransformForm did not originate from getGradeSystemTransformFormForCreate()
CompliancemandatoryThis method must be implemented.
MethodcanUpdateGradeSystemTransforms
Description

Tests if this user can update GradeSystemTransforms. A return of true does not guarantee successful authorization. A return of false indicates that it is known updating a GradeSystemTransform will result in a PERMISSION_DENIED. This is intended as a hint to an application that may not wish to offer update operations to unauthorized users.

Returnboolean false if GradeSystemTransform modification is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodgetGradeSystemTransformFormForUpdate
Description

Gets the grade system form for updating an existing grade system transform. A new grade system transform form should be requested for each update transaction.

Parametersosid.id.IdgradeSystemTransformIdthe Id of the GradeSystemTransform
Returnosid.grading.transform.GradeSystemTransformFormthe grade system transform form
ErrorsNOT_FOUND gradeSystemTransformId is not found
NULL_ARGUMENT gradeSystemTransformId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodupdateGradeSystemTransform
Description

Updates an existing grade system transform.

Parametersosid.grading.transform.GradeSystemTransformFormgradeSystemTransformFormthe form containing the elements to be updated
ErrorsILLEGAL_STATE gradeSystemTransformForm already used in an update transaction
INVALID_ARGUMENTthe form contains an invalid value
NULL_ARGUMENT gradeSystemTransformForm is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTED gradeSystemTransformForm did not originate from getGradeSystemTransformFormForUpdate()
CompliancemandatoryThis method must be implemented.
MethodcanDeleteGradeSystemTransforms
Description

Tests if this user can delete grade system transforms. A return of true does not guarantee successful authorization. A return of false indicates that it is known deleting a GradeSystemTransform will result in a PERMISSION_DENIED. This is intended as a hint to an application that may not wish to offer delete operations to unauthorized users.

Returnboolean false if GradeSystemTransform deletion is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethoddeleteGradeSystemTransform
Description

Deletes a GradeSystemTransform.

Parametersosid.id.IdgradeSystemTransformIdthe Id of the GradeSystemTransform to remove
ErrorsNOT_FOUND gradeSystemTransformId not found
NULL_ARGUMENT gradeSystemTransformId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanManageGradeSystemTransformAliases
Description

Tests if this user can manage Id aliases for GradeSystemTransforms. A return of true does not guarantee successful authorization. A return of false indicates that it is known changing an alias will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer alias operations to an unauthorized user.

Returnboolean false if GradeSystemTransform aliasing is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodaliasGradeSystemTransform
Description

Adds an Id to a GradeSystemTransform for the purpose of creating compatibility. The primary Id of the GradeSystemTransform is determined by the provider. The new Id performs as an alias to the primary Id. If the alias is a pointer to another grade system transform, it is reassigned to the given grade system transform Id.

Parametersosid.id.IdgradeSystemTransformIdthe Id of a GradeSystemTransform
osid.id.IdaliasIdthe alias Id
ErrorsALREADY_EXISTS aliasId is already assigned
NOT_FOUND gradeSystemTransformId not found
NULL_ARGUMENT gradeSystemTransformId or aliasId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodaddGradeMap
Description

Adds a direct grade mapping to a transform.

Parametersosid.id.IdgradeSystemTransformIdthe Id of a GradeSystemTransform
osid.id.IdsourceGradeIdthe source grade Id
osid.id.IdtargetGradeIdthe target grade Id
ErrorsALREADY_EXISTS sourceGradeId is already mapped
NOT_FOUND gradeSystemTransformId, sourceGradeId or targetGradeId not found
NULL_ARGUMENT gradeSystemTransformId, sourceGradeId or targetGradeId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodremoveGradeMap
Description

Removes a direct grade mapping from a transform.

Parametersosid.id.IdgradeSystemTransformIdthe Id of a GradeSystemTransform
osid.id.IdsourceGradeIdthe source grade Id
ErrorsNOT_FOUNDno mapping in gradeSystemTransformId for sourceGradeId
NULL_ARGUMENT gradeSystemTransformId or sourceGradeId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.