Interface GradeSystemGradebookAssignmentSession
- All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession
This session provides methods to re-assign grade systems to
Gradebooks . A GradeSystem may map to multiple Gradebooks
and removing the last reference to a GradeSystem is the equivalent
of deleting it. Each Gradebook may have its own authorizations
governing who is allowed to operate on it.
Moving or adding a reference of a GradeSystem to another
Gradebook is not a copy operation (eg: does not change its
Id ).
-
Method Summary
Modifier and TypeMethodDescriptionvoidassignGradeSystemToGradebook(Id gradeSystemId, Id gradebookId) Adds an existingGradeSystemto aGradebook.booleanTests if this user can alter grade system/gradebook mappings.booleancanAssignGradeSystemsToGradebook(Id gradebookId) Tests if this user can alter grade system/gradebook mappings.getAssignableGradebookIds(Id gradebookId) Gets a list of gradebooks including and under the given gradebook node in which any grade system can be assigned.getAssignableGradebookIdsForGradeSystem(Id gradebookId, Id gradeSystemId) Gets a list of gradebooks including and under the given gradebook node in which a specific grade system can be assigned.voidreassignGradeSystemToGradebook(Id gradeSystemId, Id fromGradebookId, Id toGradebookId) Moves aGradeSystemfrom oneGradebookto another.voidunassignGradeSystemFromGradebook(Id gradeSystemId, Id gradebookId) Removes aGradeSystemfrom aGradebook.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
-
canAssignGradeSystem
boolean canAssignGradeSystem()Tests if this user can alter grade system/gradebook mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping methods in this session will result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer assignment operations to unauthorized users.- Returns:
falseif mapping is not authorized,trueotherwise- Compliance:
mandatory- This method must be implemented.
-
canAssignGradeSystemsToGradebook
Tests if this user can alter grade system/gradebook mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping methods in this session will result in aPERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer assignment operations to unauthorized users.- Parameters:
gradebookId- theIdof theGradebook- Returns:
falseif mapping is not authorized,trueotherwise- Throws:
NullArgumentException-gradebookIdisnull- Compliance:
mandatory- This method must be implemented.
-
getAssignableGradebookIds
Gets a list of gradebooks including and under the given gradebook node in which any grade system can be assigned.- Parameters:
gradebookId- theIdof theGradebook- Returns:
- list of assignable gradebook
Ids - Throws:
NullArgumentException-gradebookIdisnullOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
getAssignableGradebookIdsForGradeSystem
IdList getAssignableGradebookIdsForGradeSystem(Id gradebookId, Id gradeSystemId) throws OperationFailedException Gets a list of gradebooks including and under the given gradebook node in which a specific grade system can be assigned.- Parameters:
gradebookId- theIdof theGradebookgradeSystemId- theIdof theGradeSystem- Returns:
- list of assignable gradebook
Ids - Throws:
NullArgumentException-gradebookIdorgradeSystemIdisnullOperationFailedException- unable to complete request- Compliance:
mandatory- This method must be implemented.
-
assignGradeSystemToGradebook
void assignGradeSystemToGradebook(Id gradeSystemId, Id gradebookId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Adds an existingGradeSystemto aGradebook.- Parameters:
gradeSystemId- theIdof theGradeSystemgradebookId- theIdof theGradebook- Throws:
AlreadyExistsException-gradeSystemIdis already assigned togradebookIdNotFoundException-gradeSystemIdorgradebookIdnot foundNullArgumentException-gradeSystemIdorgradebookIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
unassignGradeSystemFromGradebook
void unassignGradeSystemFromGradebook(Id gradeSystemId, Id gradebookId) throws NotFoundException, OperationFailedException, PermissionDeniedException Removes aGradeSystemfrom aGradebook.- Parameters:
gradeSystemId- theIdof theGradeSystemgradebookId- theIdof theGradebook- Throws:
NotFoundException-gradeSystemIdorgradebookIdnot found orgradeSystemIdnot assigned togradebookIdNullArgumentException-gradeSystemIdorgradebookIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-
reassignGradeSystemToGradebook
void reassignGradeSystemToGradebook(Id gradeSystemId, Id fromGradebookId, Id toGradebookId) throws AlreadyExistsException, NotFoundException, OperationFailedException, PermissionDeniedException Moves aGradeSystemfrom oneGradebookto another. Mappings to otherGradebooksare unaffected.- Parameters:
gradeSystemId- theIdof theGradeSystemfromGradebookId- theIdof the currentGradebooktoGradebookId- theIdof the destinationGradebook- Throws:
AlreadyExistsException-gradebookSystemIdalready assigned totoGradebookIdNotFoundException-gradeSystemId, fromGradebookId, ortoGradebookIdnot found orgradeSystemIdnot mapped tofromGradebookIdNullArgumentException-gradeSystemId, fromGradebookId, ortoGradebookIdisnullOperationFailedException- unable to complete requestPermissionDeniedException- authorization failure- Compliance:
mandatory- This method must be implemented.
-