Gradebook¶
Gradebook¶
-
class
dlkit.services.grading.Gradebook(provider_manager, catalog, runtime, proxy, **kwargs)¶ Bases:
dlkit.osid.objects.OsidCatalog,dlkit.osid.sessions.OsidSessionA gradebook defines a collection of grade entries.
-
get_gradebook_record(gradebook_record_type)¶ Gets the gradebook record corresponding to the given
GradebookrecordType.This method is used to retrieve an object implementing the requested record. The
gradebook_record_typemay be theTypereturned inget_record_types()or any of its parents in aTypehierarchy wherehas_record_type(gradebook_record_type)istrue.Parameters: gradebook_record_type ( osid.type.Type) – a gradebook record typeReturns: the gradebook record Return type: osid.grading.records.GradebookRecordRaise: NullArgument–gradebook_record_typeisnullRaise: OperationFailed– unable to complete requestRaise: Unsupported–has_record_type(gradebook_record_type)isfalsecompliance: mandatory – This method must be implemented.
-
Grade System Lookup Methods¶
Gradebook.gradebook_id¶Gets the
GradebookIdassociated with this session.
Returns: the Gradebook Idassociated with this sessionReturn type: osid.id.Idcompliance: mandatory – This method must be implemented.
Gradebook.gradebook¶Gets the
Gradebookassociated with this session.
Returns: the Gradebookassociated with this sessionReturn type: osid.grading.GradebookRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_lookup_grade_systems()¶Tests if this user can perform
GradeSystemlookups.A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in a
PermissionDenied. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.
Returns: falseif lookup methods are not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.use_comparative_grade_system_view()¶The returns from the lookup methods may omit or translate elements based on this session, such as authorization, and not result in an error.
This view is used when greater interoperability is desired at the expense of precision.
compliance: mandatory – This method is must be implemented.
Gradebook.use_plenary_grade_system_view()¶A complete view of the
GradeSystemreturns is desired.Methods will return what is requested or result in an error. This view is used when greater precision is desired at the expense of interoperability.
compliance: mandatory – This method is must be implemented.
Gradebook.use_federated_gradebook_view()¶Federates the view for methods in this session.
A federated view will include grade entries in gradebooks which are children of this gradebook in the gradebook hierarchy.
compliance: mandatory – This method is must be implemented.
Gradebook.use_isolated_gradebook_view()¶Isolates the view for methods in this session.
An isolated view restricts searches to this gradebook only.
compliance: mandatory – This method is must be implemented.
Gradebook.get_grade_system(grade_system_id)¶Gets the
GradeSystemspecified by itsId.In plenary mode, the exact
Idis found or aNotFoundresults. Otherwise, the returnedGradeSystemmay have a differentIdthan requested, such as the case where a duplicateIdwas assigned to aGradeSystemand retained for compatibility.
Parameters: grade_system_id ( osid.id.Id) –Idof theGradeSystemReturns: the grade system Return type: osid.grading.GradeSystemRaise: NotFound–grade_system_idnot foundRaise: NullArgument–grade_system_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method is must be implemented.
Gradebook.get_grade_system_by_grade(grade_id)¶Gets the
GradeSystemby aGradeId.
Parameters: grade_id ( osid.id.Id) –Idof aGradeReturns: the grade system Return type: osid.grading.GradeSystemRaise: NotFound–grade_idnot foundRaise: NullArgument–grade_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method is must be implemented.
Gradebook.get_grade_systems_by_ids(grade_system_ids)¶Gets a
GradeSystemListcorresponding to the givenIdList.In plenary mode, the returned list contains all of the systems specified in the
Idlist, in the order of the list, including duplicates, or an error results if anIdin the supplied list is not found or inaccessible. Otherwise, inaccessibleGradeSystemsmay be omitted from the list and may present the elements in any order including returning a unique set.
Parameters: grade_system_ids ( osid.id.IdList) – the list ofIdsto retrieveReturns: the returned GradeSystemlistReturn type: osid.grading.GradeSystemListRaise: NotFound– anId wasnot foundRaise: NullArgument–grade_system_idsisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_systems_by_genus_type(grade_system_genus_type)¶Gets a
GradeSystemListcorresponding to the given grade system genusTypewhich does not include systems of genus types derived from the specifiedType.In plenary mode, the returned list contains all known systems or an error results. Otherwise, the returned list may contain only those systems that are accessible through this session.
Parameters: grade_system_genus_type ( osid.type.Type) – a grade system genus typeReturns: the returned GradeSystemlistReturn type: osid.grading.GradeSystemListRaise: NullArgument–grade_system_genus_typeisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_systems_by_parent_genus_type(grade_system_genus_type)¶Gets a
GradeSystemListcorresponding to the given grade system genusTypeand include any additional systems with genus types derived from the specifiedType.In plenary mode, the returned list contains all known systems or an error results. Otherwise, the returned list may contain only those systems that are accessible through this session.
Parameters: grade_system_genus_type ( osid.type.Type) – a grade system genus typeReturns: the returned GradeSystemlistReturn type: osid.grading.GradeSystemListRaise: NullArgument–grade_system_genus_typeisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_systems_by_record_type(grade_system_record_type)¶Gets a
GradeSystemListcontaining the given grade recordType.In plenary mode, the returned list contains all known systems or an error results. Otherwise, the returned list may contain only those systems that are accessible through this session.
Parameters: grade_system_record_type ( osid.type.Type) – a grade system record typeReturns: the returned GradeSystemlistReturn type: osid.grading.GradeSystemListRaise: NullArgument–grade_system_genus_typeisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.grade_systems¶Gets all
GradeSystems.In plenary mode, the returned list contains all known grade systems or an error results. Otherwise, the returned list may contain only those grade systems that are accessible through this session.
Returns: a GradeSystemListReturn type: osid.grading.GradeSystemListRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Grade System Query Methods¶
Gradebook.gradebook_idGets the
GradebookIdassociated with this session.
Returns: the Gradebook Idassociated with this sessionReturn type: osid.id.Idcompliance: mandatory – This method must be implemented.
Gradebook.gradebookGets the
Gradebookassociated with this session.
Returns: the Gradebookassociated with this sessionReturn type: osid.grading.GradebookRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_search_grade_systems()¶Tests if this user can perform
GradeSystemsearches.A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in a
PermissionDenied. This is intended as a hint to an application that may opt not to offer search operations to unauthorized users.
Returns: falseif search methods are not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.use_federated_gradebook_view()Federates the view for methods in this session.
A federated view will include grade entries in gradebooks which are children of this gradebook in the gradebook hierarchy.
compliance: mandatory – This method is must be implemented.
Gradebook.use_isolated_gradebook_view()Isolates the view for methods in this session.
An isolated view restricts searches to this gradebook only.
compliance: mandatory – This method is must be implemented.
Gradebook.grade_system_query¶Gets a grade system query.
Returns: a grade system query Return type: osid.grading.GradeSystemQuerycompliance: mandatory – This method must be implemented.
Gradebook.get_grade_systems_by_query(grade_system_query)¶Gets a list of
GradeSystemobjects matching the given grade system query.
Parameters: grade_system_query ( osid.grading.GradeSystemQuery) – the grade system queryReturns: the returned GradeSystemListReturn type: osid.grading.GradeSystemListRaise: NullArgument–grade_system_queryisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported–grade_system_queryis not of this servicecompliance: mandatory – This method must be implemented.
Grade System Admin Methods¶
Gradebook.gradebook_idGets the
GradebookIdassociated with this session.
Returns: the Gradebook Idassociated with this sessionReturn type: osid.id.Idcompliance: mandatory – This method must be implemented.
Gradebook.gradebookGets the
Gradebookassociated with this session.
Returns: the Gradebookassociated with this sessionReturn type: osid.grading.GradebookRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_create_grade_systems()¶Tests if this user can create
GradeSystems.A return of true does not guarantee successful authorization. A return of false indicates that it is known creating a
GradeSystemwill result in aPermissionDenied. This is intended as a hint to an application that may not wish to offer create operations to unauthorized users.
Returns: falseifGradeSystemcreation is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.can_create_grade_system_with_record_types(grade_system_record_types)¶Tests if this user can create a single
GradeSystemusing the desired record types.While
GradingManager.getGradeSystemRecordTypes()can be used to examine which records are supported, this method tests which record(s) are required for creating a specificGradeSystem. Providing an empty array tests if aGradeSystemcan be created with no records.
Parameters: grade_system_record_types ( osid.type.Type[]) – array of grade system typesReturns: trueifGradeSystemcreation using the specifiedTypesis supported,falseotherwiseReturn type: booleanRaise: NullArgument–grade_system_record_typesisnullcompliance: mandatory – This method must be implemented.
Gradebook.get_grade_system_form_for_create(grade_system_record_types)¶Gets the grade system form for creating new grade systems.
A new form should be requested for each create transaction.
Parameters: grade_system_record_types ( osid.type.Type[]) – array of grade system typesReturns: the grade system form Return type: osid.grading.GradeSystemFormRaise: NullArgument–grade_system_record_typesisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported– unable to get form for requested record typescompliance: mandatory – This method must be implemented.
Gradebook.create_grade_system(grade_system_form)¶Creates a new
GradeSystem.
Parameters: grade_system_form ( osid.grading.GradeSystemForm) – the form for thisGradeSystemReturns: the new GradeSystemReturn type: osid.grading.GradeSystemRaise: IllegalState–grade_system_formalready used in a create transactionRaise: InvalidArgument– one or more of the form elements is invalidRaise: NullArgument–grade_system_formisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported–grade_system_formdid not originate fromget_grade_system_form_for_create()compliance: mandatory – This method must be implemented.
Gradebook.can_update_grade_systems()¶Tests if this user can update
GradeSystems.A return of true does not guarantee successful authorization. A return of false indicates that it is known updating a
GradeSystemwill result in aPermissionDenied. This is intended as a hint to an application that may not wish to offer update operations to unauthorized users.
Returns: falseifGradeSystemmodification is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.get_grade_system_form_for_update(grade_system_id)¶Gets the grade system form for updating an existing grade system.
A new grade system form should be requested for each update transaction.
Parameters: grade_system_id ( osid.id.Id) – theIdof theGradeSystemReturns: the grade system form Return type: osid.grading.GradeSystemFormRaise: NotFound–grade_system_idis not foundRaise: NullArgument–grade_system_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.update_grade_system(grade_system_form)¶Updates an existing grade system.
Parameters: grade_system_form ( osid.grading.GradeSystemForm) – the form containing the elements to be updatedRaise: IllegalState–grade_system_formalready used in an update transactionRaise: InvalidArgument– the form contains an invalid valueRaise: NullArgument–grade_system_formisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported–grade_system_formdid not originate fromget_grade_system_form_for_update()compliance: mandatory – This method must be implemented.
Gradebook.can_delete_grade_systems()¶Tests if this user can delete grade systems.
A return of true does not guarantee successful authorization. A return of false indicates that it is known deleting a
GradeSystemwill result in aPermissionDenied. This is intended as a hint to an application that may not wish to offer delete operations to unauthorized users.
Returns: falseifGradeSystemdeletion is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.delete_grade_system(grade_system_id)¶Deletes a
GradeSystem.
Parameters: grade_system_id ( osid.id.Id) – theIdof theGradeSystemto removeRaise: NotFound–grade_system_idnot foundRaise: NullArgument–grade_system_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_manage_grade_system_aliases()¶Tests if this user can manage
Idaliases forGradeSystems.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
PermissionDenied. This is intended as a hint to an application that may opt not to offer alias operations to an unauthorized user.
Returns: falseifGradeSystemaliasing is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.alias_grade_system(grade_system_id, alias_id)¶Adds an
Idto aGradeSystemfor the purpose of creating compatibility.The primary
Idof theGradeSystemis determined by the provider. The newIdperforms as an alias to the primaryId. If the alias is a pointer to another grade system, it is reassigned to the given grade systemId.
Parameters:
- grade_system_id (
osid.id.Id) – theIdof aGradeSystem- alias_id (
osid.id.Id) – the aliasIdRaise:
AlreadyExists–alias_idis already assignedRaise:
NotFound–grade_system_idnot foundRaise:
NullArgument–grade_system_idoralias_idisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_create_grades(grade_system_id)¶Tests if this user can create
Grades for aGradeSystem.A return of true does not guarantee successful authorization. A return of false indicates that it is known creating a
GradeSystemwill result in aPermissionDenied. This is intended as a hint to an application that may not wish to offer create operations to unauthorized users.
Parameters: grade_system_id ( osid.id.Id) – theIdof aGradeSystemReturns: falseifGradecreation is not authorized,trueotherwiseReturn type: booleanRaise: NullArgument–grade_system_idisnullcompliance: mandatory – This method must be implemented.
Gradebook.can_create_grade_with_record_types(grade_system_id, grade_record_types)¶Tests if this user can create a single
Gradeusing the desired record types.While
GradingManager.getGradeRecordTypes()can be used to examine which records are supported, this method tests which record(s) are required for creating a specificGrade. Providing an empty array tests if aGradecan be created with no records.
Parameters:
- grade_system_id (
osid.id.Id) – theIdof aGradeSystem- grade_record_types (
osid.type.Type[]) – array of grade recod typesReturns:
trueifGradecreation using the specifiedTypesis supported,falseotherwiseReturn type:
booleanRaise:
NullArgument–grade_system_idorgrade_record_typesisnullcompliance: mandatory – This method must be implemented.
Gradebook.get_grade_form_for_create(grade_system_id, grade_record_types)¶Gets the grade form for creating new grades.
A new form should be requested for each create transaction.
Parameters:
- grade_system_id (
osid.id.Id) – theIdof aGradeSystem- grade_record_types (
osid.type.Type[]) – array of grade recod typesReturns: the grade form
Return type:
osid.grading.GradeFormRaise:
NotFound–grade_system_idis not foundRaise:
NullArgument–grade_system_idorgrade_record_typesisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failureRaise:
Unsupported– unable to get form for requested record typescompliance: mandatory – This method must be implemented.
Gradebook.create_grade(grade_form)¶Creates a new
Grade.
Parameters: grade_form ( osid.grading.GradeForm) – the form for thisGradeReturns: the new GradeReturn type: osid.grading.GradeRaise: IllegalState–grade_formalready used in a create transactionRaise: InvalidArgument– one or more of the form elements is invalidRaise: NullArgument–grade_formisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported–grade_formdid not originate fromget_grade_form_for_create()compliance: mandatory – This method must be implemented.
Gradebook.can_update_grades(grade_system_id)¶Tests if this user can update
Grades.A return of true does not guarantee successful authorization. A return of false indicates that it is known updating a
Gradewill result in aPermissionDenied. This is intended as a hint to an application that may not wish to offer update operations to unauthorized users.
Parameters: grade_system_id ( osid.id.Id) – theIdof aGradeSystemReturns: falseifGrademodification is not authorized,trueotherwiseReturn type: booleanRaise: NullArgument–grade_system_idisnullcompliance: mandatory – This method must be implemented.
Gradebook.get_grade_form_for_update(grade_id)¶Gets the grade form for updating an existing grade.
A new grade form should be requested for each update transaction.
Parameters: grade_id ( osid.id.Id) – theIdof theGradeReturns: the grade form Return type: osid.grading.GradeFormRaise: NotFound–grade_idis not foundRaise: NullArgument–grade_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.update_grade(grade_form)¶Updates an existing grade.
Parameters: grade_form ( osid.grading.GradeForm) – the form containing the elements to be updatedRaise: IllegalState–grade_formalready used in an update transactionRaise: InvalidArgument– the form contains an invalid valueRaise: NullArgument–grade_idorgrade_formisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported–grade_formdid not originate fromget_grade_form_for_update()compliance: mandatory – This method must be implemented.
Gradebook.can_delete_grades(grade_system_id)¶Tests if this user can delete grades.
A return of true does not guarantee successful authorization. A return of false indicates that it is known deleting a
Gradewill result in aPermissionDenied. This is intended as a hint to an application that may not wish to offer delete operations to unauthorized users.
Parameters: grade_system_id ( osid.id.Id) – theIdof aGradeSystemReturns: falseifGradedeletion is not authorized,trueotherwiseReturn type: booleanRaise: NullArgument–grade_system_idisnullcompliance: mandatory – This method must be implemented.
Gradebook.delete_grade(grade_id)¶Deletes a
Grade.
Parameters: grade_id ( osid.id.Id) – theIdof theGradeto removeRaise: NotFound–grade_idnot foundRaise: NullArgument–grade_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_manage_grade_aliases()¶Tests if this user can manage
Idaliases forGrades.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
PermissionDenied. This is intended as a hint to an application that may opt not to offer alias operations to an unauthorized user.
Returns: falseifGradealiasing is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.alias_grade(grade_id, alias_id)¶Adds an
Idto aGradefor the purpose of creating compatibility.The primary
Idof theGradeis determined by the provider. The newIdperforms as an alias to the primaryId. If the alias is a pointer to another grade, it is reassigned to the given gradeId.
Parameters:
- grade_id (
osid.id.Id) – theIdof aGrade- alias_id (
osid.id.Id) – the aliasIdRaise:
AlreadyExists–alias_idis already assignedRaise:
NotFound–grade_idnot foundRaise:
NullArgument–grade_idoralias_idisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Grade Entry Lookup Methods¶
Gradebook.gradebook_idGets the
GradebookIdassociated with this session.
Returns: the Gradebook Idassociated with this sessionReturn type: osid.id.Idcompliance: mandatory – This method must be implemented.
Gradebook.gradebookGets the
Gradebookassociated with this session.
Returns: the Gradebookassociated with this sessionReturn type: osid.grading.GradebookRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_lookup_grade_entries()¶Tests if this user can perform
GradeEntrylookups.A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in a
PermissionDenied. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.
Returns: falseif lookup methods are not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.use_comparative_grade_entry_view()¶The returns from the lookup methods may omit or translate elements based on this session, such as authorization, and not result in an error.
This view is used when greater interoperability is desired at the expense of precision.
compliance: mandatory – This method is must be implemented.
Gradebook.use_plenary_grade_entry_view()¶A complete view of the
GradeEntryreturns is desired.Methods will return what is requested or result in an error. This view is used when greater precision is desired at the expense of interoperability.
compliance: mandatory – This method is must be implemented.
Gradebook.use_federated_gradebook_view()Federates the view for methods in this session.
A federated view will include grade entries in gradebooks which are children of this gradebook in the gradebook hierarchy.
compliance: mandatory – This method is must be implemented.
Gradebook.use_isolated_gradebook_view()Isolates the view for methods in this session.
An isolated view restricts searches to this gradebook only.
compliance: mandatory – This method is must be implemented.
Gradebook.use_effective_grade_entry_view()¶Only grade entries whose effective dates are current are returned by methods in this session.
compliance: mandatory – This method is must be implemented.
Gradebook.use_any_effective_grade_entry_view()¶All grade entries of any effective dates are returned by methods in this session.
compliance: mandatory – This method is must be implemented.
Gradebook.get_grade_entry(grade_entry_id)¶Gets the
GradeEntryspecified by itsId.
Parameters: grade_entry_id ( osid.id.Id) –Idof theGradeEntryReturns: the grade entry Return type: osid.grading.GradeEntryRaise: NotFound–grade_entry_idnot foundRaise: NullArgument–grade_entry_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method is must be implemented.
Gradebook.get_grade_entries_by_ids(grade_entry_ids)¶Gets a
GradeEntryListcorresponding to the givenIdList.
Parameters: grade_entry_ids ( osid.id.IdList) – the list ofIdsto retrieveReturns: the returned GradeEntrylistReturn type: osid.grading.GradeEntryListRaise: NotFound– anId wasnot foundRaise: NullArgument–grade_entry_idsisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_by_genus_type(grade_entry_genus_type)¶Gets a
GradeEntryListcorresponding to the given grade entry genusTypewhich does not include grade entries of genus types derived from the specifiedType.
Parameters: grade_entry_genus_type ( osid.type.Type) – a grade entry genus typeReturns: the returned GradeEntrylistReturn type: osid.grading.GradeEntryListRaise: NullArgument–grade_entry_genus_typeisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_by_parent_genus_type(grade_entry_genus_type)¶Gets a
GradeEntryListcorresponding to the given grade entry genusTypeand include any additional grade entry with genus types derived from the specifiedType.
Parameters: grade_entry_genus_type ( osid.type.Type) – a grade entry genus typeReturns: the returned GradeEntrylistReturn type: osid.grading.GradeEntryListRaise: NullArgument–grade_entry_genus_typeisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_by_record_type(grade_entry_record_type)¶Gets a
GradeEntryListcontaining the given grade entry recordType.
Parameters: grade_entry_record_type ( osid.type.Type) – a grade entry record typeReturns: the returned GradeEntrylistReturn type: osid.grading.GradeEntryListRaise: NullArgument–grade_entry_record_typeisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_on_date(from_, to)¶Gets a
GradeEntryListeffective during the entire given date range inclusive but not confined to the date range.
Parameters:
- from (
osid.calendaring.DateTime) – start of date range- to (
osid.calendaring.DateTime) – end of date rangeReturns: the returned
GradeEntrylistReturn type:
osid.grading.GradeEntryListRaise:
InvalidArgument–fromis greater thantoRaise:
NullArgument–from or toisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_for_gradebook_column(gradebook_column_id)¶Gets a
GradeEntryListfor the gradebook column.
Parameters: gradebook_column_id ( osid.id.Id) – a gradebook columnIdReturns: the returned GradeEntrylistReturn type: osid.grading.GradeEntryListRaise: NullArgument–gradebook_column_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_for_gradebook_column_on_date(gradebook_column_id, from_, to)¶Gets a
GradeEntryListfor the given gradebook column and effective during the entire given date range inclusive but not confined to the date range.
Parameters:
- gradebook_column_id (
osid.id.Id) – a gradebook columnId- from (
osid.calendaring.DateTime) – start of date range- to (
osid.calendaring.DateTime) – end of date rangeReturns: the returned
GradeEntrylistReturn type:
osid.grading.GradeEntryListRaise:
InvalidArgument–fromis greater thantoRaise:
NullArgument–gradebook_column_id, from, or toisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_for_resource(resource_id)¶Gets a
GradeEntryListfor the given key key resource.
Parameters: resource_id ( osid.id.Id) – a key resourceIdReturns: the returned GradeEntrylistReturn type: osid.grading.GradeEntryListRaise: NullArgument–resource_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_for_resource_on_date(resource_id, from_, to)¶Gets a
GradeEntryListfor the given key resource and effective during the entire given date range inclusive but not confined to the date range.
Parameters:
- resource_id (
osid.id.Id) – a resourceId- from (
osid.calendaring.DateTime) – start of date range- to (
osid.calendaring.DateTime) – end of date rangeReturns: the returned
GradeEntrylistReturn type:
osid.grading.GradeEntryListRaise:
InvalidArgument–fromis greater thantoRaise:
NullArgument–resource_id, from, or toisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_for_gradebook_column_and_resource(gradebook_column_id, resource_id)¶Gets a
GradeEntryListfor the gradebook column and key resource.
Parameters:
- gradebook_column_id (
osid.id.Id) – a gradebook columnId- resource_id (
osid.id.Id) – a key resourceIdReturns: the returned
GradeEntrylistReturn type:
osid.grading.GradeEntryListRaise:
NullArgument–gradebook_column_idorresource_idisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_for_gradebook_column_and_resource_on_date(gradebook_column_id, resource_id, from_, to)¶Gets a
GradeEntryListfor the given gradebook column, resource, and effective during the entire given date range inclusive but not confined to the date range.
Parameters:
- gradebook_column_id (
osid.id.Id) – a gradebook columnId- resource_id (
osid.id.Id) – a key resourceId- from (
osid.calendaring.DateTime) – start of date range- to (
osid.calendaring.DateTime) – end of date rangeReturns: the returned
GradeEntrylistReturn type:
osid.grading.GradeEntryListRaise:
InvalidArgument–fromis greater thantoRaise:
NullArgument–gradebook_column_id, resource, from, or toisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_by_grader(resource_id)¶Gets a
GradeEntryListfor the given grader.
Parameters: resource_id ( osid.id.Id) – a resourceIdReturns: the returned GradeEntrylistReturn type: osid.grading.GradeEntryListRaise: NullArgument–resource_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.grade_entries¶Gets all grade entries.
Returns: a GradeEntryListReturn type: osid.grading.GradeEntryListRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Grade Entry Query Methods¶
Gradebook.gradebook_idGets the
GradebookIdassociated with this session.
Returns: the Gradebook Idassociated with this sessionReturn type: osid.id.Idcompliance: mandatory – This method must be implemented.
Gradebook.gradebookGets the
Gradebookassociated with this session.
Returns: the Gradebookassociated with this sessionReturn type: osid.grading.GradebookRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_search_grade_entries()¶Tests if this user can perform
GradeEntrysearches.A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in a
PermissionDenied. This is intended as a hint to an application that may opt not to offer search operations to unauthorized users.
Returns: falseif search methods are not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.use_federated_gradebook_view()Federates the view for methods in this session.
A federated view will include grade entries in gradebooks which are children of this gradebook in the gradebook hierarchy.
compliance: mandatory – This method is must be implemented.
Gradebook.use_isolated_gradebook_view()Isolates the view for methods in this session.
An isolated view restricts searches to this gradebook only.
compliance: mandatory – This method is must be implemented.
Gradebook.grade_entry_query¶Gets a grade entry query.
Returns: the grade entry query Return type: osid.grading.GradeEntryQuerycompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entries_by_query(grade_entry_query)¶Gets a list of entries matching the given grade entry query.
Parameters: grade_entry_query ( osid.grading.GradeEntryQuery) – the grade entry queryReturns: the returned GradeEntryListReturn type: osid.grading.GradeEntryListRaise: NullArgument–grade_entry_queryisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported–grade_entry_queryis not of this servicecompliance: mandatory – This method must be implemented.
Grade Entry Admin Methods¶
Gradebook.gradebook_idGets the
GradebookIdassociated with this session.
Returns: the Gradebook Idassociated with this sessionReturn type: osid.id.Idcompliance: mandatory – This method must be implemented.
Gradebook.gradebookGets the
Gradebookassociated with this session.
Returns: the Gradebookassociated with this sessionReturn type: osid.grading.GradebookRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_create_grade_entries()¶Tests if this user can create grade entries.
A return of true does not guarantee successful authorization. A return of false indicates that it is known creating a grade entry will result in a
PermissionDenied. This is intended as a hint to an application that may opt not to offer create operations to an unauthorized user.
Returns: falseifGradeEntrycreation is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.can_create_grade_entry_with_record_types(grade_entry_record_types)¶Tests if this user can create a single
GradeEntryusing the desired record types.While
GradingManager.getGradeEntryRecordTypes()can be used to examine which records are supported, this method tests which record(s) are required for creating a specificGradeEntry. Providing an empty array tests if aGradeEntrycan be created with no records.
Parameters: grade_entry_record_types ( osid.type.Type[]) – array of grade entry record typesReturns: trueifGradeEntrycreation using the specified recordTypesis supported,falseotherwiseReturn type: booleanRaise: NullArgument–grade_entry_record_typesisnullcompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entry_form_for_create(gradebook_column_id, resource_id, grade_entry_record_types)¶Gets the grade entry form for creating new grade entries.
A new form should be requested for each create transaction.
Parameters:
- gradebook_column_id (
osid.id.Id) – the gradebook column- resource_id (
osid.id.Id) – the key resource- grade_entry_record_types (
osid.type.Type[]) – array of grade entry record typesReturns: the grade entry form
Return type:
osid.grading.GradeEntryFormRaise:
NotFound–gradebook_column_id or resource_idnot foundRaise:
NullArgument–gradebook_column_id, resource_id,orgrade_entry_record_typesisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failureRaise:
Unsupported– unable to get form for requested record typescompliance: mandatory – This method must be implemented.
Gradebook.create_grade_entry(grade_entry_form)¶Creates a new
GradeEntry.
Parameters: grade_entry_form ( osid.grading.GradeEntryForm) – the form for thisGradeEntryReturns: the new GradeEntryReturn type: osid.grading.GradeEntryRaise: IllegalState–grade_entry_formalready used in a create transactionRaise: InvalidArgument– one or more of the form elements is invalidRaise: NullArgument–grade_entry_formisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported–grade_entry_formdid not originate fromget_grade_entry_form_for_create()compliance: mandatory – This method must be implemented.
Gradebook.can_overridecalculated_grade_entries()¶Tests if this user can override grade entries calculated from another.
A return of true does not guarantee successful authorization. A return of false indicates that it is known creating a grade entry will result in a
PermissionDenied. This is intended as a hint to an application that may opt not to offer create operations to an unauthorized user.
Returns: falseifGradeEntryoverride is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entry_form_for_override(grade_entry_id, grade_entry_record_types)¶Gets the grade entry form for overriding calculated grade entries.
A new form should be requested for each create transaction.
Parameters:
- grade_entry_id (
osid.id.Id) – theIdof the grade entry to be overridden- grade_entry_record_types (
osid.type.Type[]) – array of grade entry record typesReturns: the grade entry form
Return type:
osid.grading.GradeEntryFormRaise:
AlreadyExists–grade_entry_idis already overriddenRaise:
NotFound–grade_entry_idnot found orgrade_entry_idis not a calculated entryRaise:
NullArgument–grade_entry_idorgrade_entry_record_typesisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failureRaise:
Unsupported– unable to get form for requested record typescompliance: mandatory – This method must be implemented.
Gradebook.override_calculated_grade_entry(grade_entry_form)¶Creates a new overriding
GradeEntry.
Parameters: grade_entry_form ( osid.grading.GradeEntryForm) – the form for thisGradeEntryReturns: the new GradeEntryReturn type: osid.grading.GradeEntryRaise: IllegalState–grade_entry_formalready used in a create transactionRaise: InvalidArgument– one or more of the form elements is invalidRaise: NullArgument–grade_entry_formisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported–grade_entry_formdid not originate fromget_grade_entry_form_for_override()compliance: mandatory – This method must be implemented.
Gradebook.can_update_grade_entries()¶Tests if this user can update grade entries.
A return of true does not guarantee successful authorization. A return of false indicates that it is known updating a
GradeEntrywill result in aPermissionDenied. This is intended as a hint to an application that may opt not to offer update operations to an unauthorized user.
Returns: falseif grade entry modification is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.get_grade_entry_form_for_update(grade_entry_id)¶Gets the grade entry form for updating an existing entry.
A new grade entry form should be requested for each update transaction.
Parameters: grade_entry_id ( osid.id.Id) – theIdof theGradeEntryReturns: the grade entry form Return type: osid.grading.GradeEntryFormRaise: NotFound–grade_entry_idis not foundRaise: NullArgument–grade_entry_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.update_grade_entry(grade_entry_form)¶Updates an existing grade entry.
Parameters: grade_entry_form ( osid.grading.GradeEntryForm) – the form containing the elements to be updatedRaise: IllegalState–grade_entry_formalready used in an update transactionRaise: InvalidArgument– the form contains an invalid valueRaise: NullArgument–grade_entry_formisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failureRaise: Unsupported–grade_entry_formdid not originate fromget_grade_entry_form_for_update()compliance: mandatory – This method must be implemented.
Gradebook.can_delete_grade_entries()¶Tests if this user can delete grade entries.
A return of true does not guarantee successful authorization. A return of false indicates that it is known deleting a
GradeEntrywill result in aPermissionDenied. This is intended as a hint to an application that may opt not to offer delete operations to an unauthorized user.
Returns: falseifGradeEntrydeletion is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.delete_grade_entry(grade_entry_id)¶Deletes the
GradeEntryidentified by the givenId.
Parameters: grade_entry_id ( osid.id.Id) – theIdof theGradeEntryto deleteRaise: NotFound– aGradeEntrywas not found identified by the givenIdRaise: NullArgument–grade_entry_idisnullRaise: OperationFailed– unable to complete requestRaise: PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.
Gradebook.can_manage_grade_entry_aliases()¶Tests if this user can manage
Idaliases forGradeEntries.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
PermissionDenied. This is intended as a hint to an application that may opt not to offer alias operations to an unauthorized user.
Returns: falseifGradeEntryaliasing is not authorized,trueotherwiseReturn type: booleancompliance: mandatory – This method must be implemented.
Gradebook.alias_grade_entry(grade_entry_id, alias_id)¶Adds an
Idto aGradeEntryfor the purpose of creating compatibility.The primary
Idof theGradeEntryis determined by the provider. The newIdperforms as an alias to the primaryId. If the alias is a pointer to another grade entry, it is reassigned to the given grade entryId.
Parameters:
- grade_entry_id (
osid.id.Id) – theIdof aGradeEntry- alias_id (
osid.id.Id) – the aliasIdRaise:
AlreadyExists–alias_idis already assignedRaise:
NotFound–grade_entry_idnot foundRaise:
NullArgument–grade_entry_idoralias_idisnullRaise:
OperationFailed– unable to complete requestRaise:
PermissionDenied– authorization failurecompliance: mandatory – This method must be implemented.