Queries

Grade Query

class dlkit.grading.queries.GradeQuery

Bases: dlkit.osid.queries.OsidObjectQuery, dlkit.osid.queries.OsidSubjugateableQuery

This is the query for searching gradings.

Each method match request produces an AND term while multiple invocations of a method produces a nested OR.

match_grade_system_id(grade_system_id, match)

Sets the grade system Id for this query.

Parameters:
  • grade_system_id (osid.id.Id) – a grade system Id
  • match (boolean) – true for a positive match, false for negative match
Raise:

NullArgumentgrade_system_id is null

compliance: mandatory – This method must be implemented.

grade_system_id_terms
supports_grade_system_query()

Tests if a GradeSystemQuery is available for querying grade systems.

Returns:true if a grade system query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grade_system_query

Gets the query for a grade system.

Multiple retrievals produce a nested OR term.

Returns:the grade system query
Return type:osid.grading.GradeSystemQuery
Raise:Unimplementedsupports_grade_system_query() is false

compliance: optional – This method must be implemented if ``supports_grade_system_query()`` is ``true``.

grade_system_terms
match_input_score_start_range(start, end, match)

Matches grades with the start input score inclusive.

Parameters:
  • start (decimal) – start of range
  • end (decimal) – end of range
  • match (boolean) – true for a positive match, false for negative match
Raise:

InvalidArgumentstart is greater than end

compliance: mandatory – This method must be implemented.

input_score_start_range_terms
match_input_score_end_range(start, end, match)

Matches grades with the end input score inclusive.

Parameters:
  • start (decimal) – start of range
  • end (decimal) – end of range
  • match (boolean) – true for a positive match, false for negative match
Raise:

InvalidArgumentstart is greater than end

compliance: mandatory – This method must be implemented.

input_score_end_range_terms
match_input_score(start, end, match)

Matches grades with the input score range contained within the given range inclusive.

Parameters:
  • start (decimal) – start of range
  • end (decimal) – end of range
  • match (boolean) – true for a positive match, false for negative match
Raise:

InvalidArgumentstart is greater than end

compliance: mandatory – This method must be implemented.

input_score_terms
match_output_score(start, end, match)

Matches grades with the output score contained within the given range inclusive.

Parameters:
  • start (decimal) – start of range
  • end (decimal) – end of range
  • match (boolean) – true for a positive match, false for negative match
Raise:

InvalidArgumentstart is greater than end

compliance: mandatory – This method must be implemented.

output_score_terms
match_grade_entry_id(grade_entry_id, match)

Sets the grade entry Id for this query.

Parameters:
  • grade_entry_id (osid.id.Id) – a grade entry Id
  • match (boolean) – true for a positive match, false for negative match
Raise:

NullArgumentgrade_entry_id is null

compliance: mandatory – This method must be implemented.

grade_entry_id_terms
supports_grade_entry_query()

Tests if a GradeEntryQuery is available for querying grade entries.

Returns:true if a grade entry query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grade_entry_query

Gets the query for a grade entry.

Multiple retrievals produce a nested OR term.

Returns:the grade entry query
Return type:osid.grading.GradeEntryQuery
Raise:Unimplementedsupports_grade_entry_query() is false

compliance: optional – This method must be implemented if ``supports_grade_entry_query()`` is ``true``.

match_any_grade_entry(match)

Matches grades that are assigned to any grade entry.

Parameters:match (boolean) – true to match grades used in any grade entry, false to match grades that are not used in any grade entries

compliance: mandatory – This method must be implemented.

grade_entry_terms
match_gradebook_id(gradebook_id, match)

Sets the gradebook Id for this query.

Parameters:
  • gradebook_id (osid.id.Id) – a gradebook Id
  • match (boolean) – true for a positive match, false for negative match
Raise:

NullArgumentgradebook_id is null

compliance: mandatory – This method must be implemented.

gradebook_id_terms
supports_gradebook_query()

Tests if a GradebookQuery is available.

Returns:true if a gradebook query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_query

Gets the query for a gradebook.

Multiple retrievals produce a nested OR term.

Returns:the gradebook query
Return type:osid.grading.GradebookQuery
Raise:Unimplementedsupports_gradebook_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_column_query()`` is ``true``.

gradebook_terms
get_grade_query_record(grade_record_type)

Gets the grade query record corresponding to the given Grade record Type.

Multiple retrievals produce a nested OR term.

Parameters:grade_record_type (osid.type.Type) – a grade record type
Returns:the grade query record
Return type:osid.grading.records.GradeQueryRecord
Raise:NullArgumentgrade_record_type is null
Raise:OperationFailed – unable to complete request
Raise:Unsupportedhas_record_type(grade_record_type) is false

compliance: mandatory – This method must be implemented.

Grade System Query

class dlkit.grading.queries.GradeSystemQuery

Bases: dlkit.osid.queries.OsidObjectQuery, dlkit.osid.queries.OsidAggregateableQuery

This is the query for searching grade systems.

Each method match request produces an AND term while multiple invocations of a method produces a nested OR.

match_based_on_grades(match)

Matches grade systems based on grades.

Parameters:match (boolean) – true for a positive match, false for negative match

compliance: mandatory – This method must be implemented.

based_on_grades_terms
match_grade_id(grade_id, match)

Sets the grade Id for this query.

Parameters:
  • grade_id (osid.id.Id) – a grade Id
  • match (boolean) – true for a positive match, false for negative match
Raise:

NullArgumentgrade_id is null

compliance: mandatory – This method must be implemented.

grade_id_terms
supports_grade_query()

Tests if a GradeQuery is available for querying grades.

Returns:true if a grade query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grade_query

Gets the query for a grade.

Multiple retrievals produce a nested OR term.

Returns:the grade query
Return type:osid.grading.GradeQuery
Raise:Unimplementedsupports_grade_query() is false

compliance: optional – This method must be implemented if ``supports_grade_query()`` is ``true``.

match_any_grade(match)

Matches grade systems with any grade.

Parameters:match (boolean) – true to match grade systems with any grade, false to match systems with no grade

compliance: mandatory – This method must be implemented.

grade_terms
match_lowest_numeric_score(start, end, match)

Matches grade systems whose low end score falls in the specified range inclusive.

Parameters:
  • start (decimal) – low end of range
  • end (decimal) – high end of range
  • match (boolean) – true for a positive match, false for negative match
Raise:

InvalidArgumentend is less than start

Raise:

NullArgumentgrade_id is null

compliance: mandatory – This method must be implemented.

lowest_numeric_score_terms
match_numeric_score_increment(start, end, match)

Matches grade systems numeric score increment is between the specified range inclusive.

Parameters:
  • start (decimal) – low end of range
  • end (decimal) – high end of range
  • match (boolean) – true for a positive match, false for negative match
Raise:

InvalidArgumentend is less than start

Raise:

NullArgumentgrade_id is null

compliance: mandatory – This method must be implemented.

numeric_score_increment_terms
match_highest_numeric_score(start, end, match)

Matches grade systems whose high end score falls in the specified range inclusive.

Parameters:
  • start (decimal) – low end of range
  • end (decimal) – high end of range
  • match (boolean) – true for a positive match, false for negative match
Raise:

InvalidArgumentend is less than start

Raise:

NullArgumentgrade_id is null

compliance: mandatory – This method must be implemented.

highest_numeric_score_terms
match_gradebook_column_id(gradebook_column_id, match)

Sets the gradebook column Id for this query.

Parameters:
  • gradebook_column_id (osid.id.Id) – a gradebook column Id
  • match (boolean) – true for a positive match, false for negative match
Raise:

NullArgumentgradebook_column_id is null

compliance: mandatory – This method must be implemented.

gradebook_column_id_terms
supports_gradebook_column_query()

Tests if a GradebookColumnQuery is available.

Returns:true if a gradebook column query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_column_query

Gets the query for a gradebook column.

Multiple retrievals produce a nested OR term.

Returns:the gradebook column query
Return type:osid.grading.GradebookColumnQuery
Raise:Unimplementedsupports_gradebook_column_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_column_query()`` is ``true``.

match_any_gradebook_column(match)

Matches grade systems assigned to any gradebook column.

Parameters:match (boolean) – true to match grade systems mapped to any column, false to match systems mapped to no columns

compliance: mandatory – This method must be implemented.

gradebook_column_terms
match_gradebook_id(gradebook_id, match)

Sets the gradebook Id for this query.

Parameters:
  • gradebook_id (osid.id.Id) – a gradebook Id
  • match (boolean) – true for a positive match, false for negative match
Raise:

NullArgumentgradebook_id is null

compliance: mandatory – This method must be implemented.

gradebook_id_terms
supports_gradebook_query()

Tests if a GradebookQuery is available.

Returns:true if a gradebook query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_query

Gets the query for a gradebook.

Multiple retrievals produce a nested OR term.

Returns:the gradebook query
Return type:osid.grading.GradebookQuery
Raise:Unimplementedsupports_gradebook_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_query()`` is ``true``.

gradebook_terms
get_grade_system_query_record(grade_system_record_type)

Gets the grade system query record corresponding to the given GradeSystem record Type.

Multiple retrievals produce a nested OR term.

Parameters:grade_system_record_type (osid.type.Type) – a grade system record type
Returns:the grade system query record
Return type:osid.grading.records.GradeSystemQueryRecord
Raise:NullArgumentgrade_system_record_type is null
Raise:OperationFailed – unable to complete request
Raise:Unsupportedhas_record_type(grade_system_record_type) is false

compliance: mandatory – This method must be implemented.

Grade Entry Query

class dlkit.grading.queries.GradeEntryQuery

Bases: dlkit.osid.queries.OsidRelationshipQuery

This is the query for searching grade entries.

Each method match request produces an AND term while multiple invocations of a method produces a nested OR.

match_gradebook_column_id(gradebook_column_id, match)

Sets the gradebook column Id for this query.

Parameters:
  • gradebook_column_id (osid.id.Id) – a gradebook column Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgradebook_column_id is null

compliance: mandatory – This method must be implemented.

gradebook_column_id_terms
supports_gradebook_column_query()

Tests if a GradebookColumnQuery is available for querying creators.

Returns:true if a gradebook column query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_column_query

Gets the query for a gradebook column.

Multiple retrievals produce a nested OR term.

Returns:the gradebook column query
Return type:osid.grading.GradebookColumnQuery
Raise:Unimplementedsupports_gradebook_column_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_column_query()`` is ``true``.

gradebook_column_terms
match_key_resource_id(resource_id, match)

Sets the key resource Id for this query.

Parameters:
  • resource_id (osid.id.Id) – a resource Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentresource_id is null

compliance: mandatory – This method must be implemented.

key_resource_id_terms
supports_key_resource_query()

Tests if a ResourceQUery is available for querying key resources.

Returns:true if a resource query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

key_resource_query

Gets the query for a key resource.

Multiple retrievals produce a nested OR term.

Returns:the resource query
Return type:osid.resource.ResourceQuery
Raise:Unimplementedsupports_key_resource_query() is false

compliance: optional – This method must be implemented if ``supports_key_resource_query()`` is ``true``.

match_any_key_resource(match)

Matches grade entries with any key resource.

Parameters:match (boolean) – true to match grade entries with any key resource, false to match entries with no key resource

compliance: mandatory – This method must be implemented.

key_resource_terms
match_derived(match)

Matches derived grade entries.

Parameters:match (boolean) – true to match derived grade entries , false to match manual entries

compliance: mandatory – This method must be implemented.

derived_terms
match_overridden_grade_entry_id(grade_entry_id, match)

Sets the grade entry Id for an overridden calculated grade entry.

Parameters:
  • grade_entry_id (osid.id.Id) – a grade entry Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgrade_entry_id is null

compliance: mandatory – This method must be implemented.

overridden_grade_entry_id_terms
supports_overridden_grade_entry_query()

Tests if a GradeEntry is available for querying overridden calculated grade entries.

Returns:true if a grade entry query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

overridden_grade_entry_query

Gets the query for an overridden derived grade entry.

Multiple retrievals produce a nested OR term.

Returns:the grade entry query
Return type:osid.grading.GradeEntryQuery
Raise:Unimplementedsupports_overridden_grade_entry_query() is false

compliance: optional – This method must be implemented if ``supports_overridden_grade_entry_query()`` is ``true``.

match_any_overridden_grade_entry(match)

Matches grade entries overriding any calculated grade entry.

Parameters:match (boolean) – true to match grade entries overriding any grade entry, false to match entries not overriding any entry

compliance: mandatory – This method must be implemented.

overridden_grade_entry_terms
match_ignored_for_calculations(match)

Matches grade entries ignored for calculations.

Parameters:match (boolean) – true to match grade entries ignored for calculations, false to match entries used in calculations

compliance: mandatory – This method must be implemented.

ignored_for_calculations_terms
match_grade_id(grade_id, match)

Sets the grade Id for this query.

Parameters:
  • grade_id (osid.id.Id) – a grade Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgrade_id is null

compliance: mandatory – This method must be implemented.

grade_id_terms
supports_grade_query()

Tests if a GradeQuery is available for querying grades.

Returns:true if a grade query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grade_query

Gets the query for a grade.

Multiple retrievals produce a nested OR term.

Returns:the grade query
Return type:osid.grading.GradeQuery
Raise:Unimplementedsupports_grade_query() is false

compliance: optional – This method must be implemented if ``supports_grade_query()`` is ``true``.

match_any_grade(match)

Matches grade entries with any grade.

Parameters:match (boolean) – true to match grade entries with any grade, false to match entries with no grade

compliance: mandatory – This method must be implemented.

grade_terms
match_score(start, end, match)

Matches grade entries which score is between the specified score inclusive.

Parameters:
  • start (decimal) – start of range
  • end (decimal) – end of range
  • match (boolean) – true for a positive match, false for a negative match
Raise:

InvalidArgumentend is less than start

compliance: mandatory – This method must be implemented.

match_any_score(match)

Matches grade entries with any score.

Parameters:match (boolean) – true to match grade entries with any score, false to match entries with no score

compliance: mandatory – This method must be implemented.

score_terms
match_time_graded(start, end, match)

Matches grade entries which graded time is between the specified times inclusive.

Parameters:
  • start (osid.calendaring.DateTime) – start of range
  • end (osid.calendaring.DateTime) – end of range
  • match (boolean) – true for a positive match, false for a negative match
Raise:

InvalidArgumentend is less than start

compliance: mandatory – This method must be implemented.

time_graded_terms
match_grader_id(resource_id, match)

Sets the agent Id for this query.

Parameters:
  • resource_id (osid.id.Id) – a resource Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentresource_id is null

compliance: mandatory – This method must be implemented.

grader_id_terms
supports_grader_query()

Tests if a ResourceQuery is available for querying graders.

Returns:true if a resource query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grader_query

Gets the query for an agent.

Multiple retrievals produce a nested OR term.

Returns:the resource query
Return type:osid.resource.ResourceQuery
Raise:Unimplementedsupports_resource_query() is false

compliance: optional – This method must be implemented if ``supports_resource_query()`` is ``true``.

match_any_grader(match)

Matches grade entries with any grader.

Parameters:match (boolean) – true to match grade entries with any grader, false to match entries with no grader

compliance: mandatory – This method must be implemented.

grader_terms
match_grading_agent_id(agent_id, match)

Sets the grading agent Id for this query.

Parameters:
  • agent_id (osid.id.Id) – an agent Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentagent_id is null

compliance: mandatory – This method must be implemented.

grading_agent_id_terms
supports_grading_agent_query()

Tests if an AgentQuery is available for querying grading agents.

Returns:true if an agent query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grading_agent_query

Gets the query for an agent.

Multiple retrievals produce a nested OR term.

Returns:the agent query
Return type:osid.authentication.AgentQuery
Raise:Unimplementedsupports_grading_agent_query() is false

compliance: optional – This method must be implemented if ``supports_grading_agent_query()`` is ``true``.

match_any_grading_agent(match)

Matches grade entries with any grading agent.

Parameters:match (boolean) – true to match grade entries with any grading agent, false to match entries with no grading agent

compliance: mandatory – This method must be implemented.

grading_agent_terms
match_gradebook_id(gradebook_id, match)

Sets the gradebook Id for this query.

Parameters:
  • gradebook_id (osid.id.Id) – a gradebook Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgradebook_id is null

compliance: mandatory – This method must be implemented.

gradebook_id_terms
supports_gradebook_query()

Tests if a GradebookQuery is available for querying resources.

Returns:true if a gradebook query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_query

Gets the query for a gradebook.

Multiple retrievals produce a nested OR term.

Returns:the gradebook query
Return type:osid.grading.GradebookQuery
Raise:Unimplementedsupports_gradebook_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_query()`` is ``true``.

gradebook_terms
get_grade_entry_query_record(grade_entry_record_type)

Gets the grade entry query record corresponding to the given GradeEntry record Type.

Multiple retrievals produce a nested OR term.

Parameters:grade_entry_record_type (osid.type.Type) – a grade entry record type
Returns:the grade entry query record
Return type:osid.grading.records.GradeEntryQueryRecord
Raise:NullArgumentgrade_entry_record_type is null
Raise:OperationFailed – unable to complete request
Raise:Unsupportedhas_record_type(grade_entry_record_type) is false

compliance: mandatory – This method must be implemented.

Gradebook Column Query

class dlkit.grading.queries.GradebookColumnQuery

Bases: dlkit.osid.queries.OsidObjectQuery

This is the query for searching gradings.

Each method match request produces an AND term while multiple invocations of a method produces a nested OR.

match_grade_system_id(grade_system_id, match)

Sets the grade system Id for this query.

Parameters:
  • grade_system_id (osid.id.Id) – a grade system Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgrade_system_id is null

compliance: mandatory – This method must be implemented.

grade_system_id_terms
supports_grade_system_query()

Tests if a GradeSystemQuery is available for querying grade systems.

Returns:true if a grade system query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grade_system_query

Gets the query for a grade system.

Multiple retrievals produce a nested OR term.

Returns:the grade system query
Return type:osid.grading.GradeSystemQuery
Raise:Unimplementedsupports_grade_system_query() is false

compliance: optional – This method must be implemented if ``supports_grade_system_query()`` is ``true``.

match_any_grade_system(match)

Matches gradebook columns with any grade system assigned.

Parameters:match (boolean) – true to match columns with any grade system, false to match columns with no grade system

compliance: mandatory – This method must be implemented.

grade_system_terms
match_grade_entry_id(grade_entry_id, match)

Sets the grade entry Id for this query.

Parameters:
  • grade_entry_id (osid.id.Id) – a grade entry Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgrade_entry_id is null

compliance: mandatory – This method must be implemented.

grade_entry_id_terms
supports_grade_entry_query()

Tests if a GradeEntryQuery is available for querying grade entries.

Returns:true if a grade entry query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grade_entry_query

Gets the query for a grade entry.

Multiple retrievals produce a nested OR term.

Returns:the grade entry query
Return type:osid.grading.GradeEntryQuery
Raise:Unimplementedsupports_grade_entry_query() is false

compliance: optional – This method must be implemented if ``supports_grade_entry_query()`` is ``true``.

match_any_grade_entry(match)

Matches gradebook columns with any grade entry assigned.

Parameters:match (boolean) – true to match columns with any grade entry, false to match columns with no grade entries

compliance: mandatory – This method must be implemented.

grade_entry_terms
supports_gradebook_column_summary_query()

Tests if a GradebookColumnSummaryQuery is available for querying grade systems.

Returns:true if a gradebook column summary query interface is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_column_summary_query

Gets the query interface for a gradebook column summary.

Multiple retrievals produce a nested OR term.

Returns:the gradebook column summary query
Return type:osid.grading.GradebookColumnSummaryQuery
Raise:Unimplementedsupports_gradebook_column_summary_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_column_summary_query()`` is ``true``.

gradebook_column_summary_terms
match_gradebook_id(gradebook_id, match)

Sets the gradebook Id for this query.

Parameters:
  • gradebook_id (osid.id.Id) – a gradebook Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgradebook_id is null

compliance: mandatory – This method must be implemented.

gradebook_id_terms
supports_gradebook_query()

Tests if a GradebookQuery is available for querying grade systems.

Returns:true if a gradebook query interface is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_query

Gets the query interface for a gradebook.

Multiple retrievals produce a nested OR term.

Returns:the gradebook query
Return type:osid.grading.GradebookQuery
Raise:Unimplementedsupports_gradebook_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_query()`` is ``true``.

gradebook_terms
get_gradebook_column_query_record(gradebook_column_record_type)

Gets the gradebook column query record corresponding to the given GradebookColumn record Type.

Multiple retrievals produce a nested OR term.

Parameters:gradebook_column_record_type (osid.type.Type) – a gradebook column record type
Returns:the gradebook column query record
Return type:osid.grading.records.GradebookColumnQueryRecord
Raise:NullArgumentgradebook_column_record_type is null
Raise:OperationFailed – unable to complete request
Raise:Unsupportedhas_record_type(gradebook_column_record_type) is false

compliance: mandatory – This method must be implemented.

Gradebook Column Summary Query

class dlkit.grading.queries.GradebookColumnSummaryQuery

Bases: dlkit.osid.queries.OsidRuleQuery

This is the query for searching gradebook column summaries.

Each method match request produces an AND term while multiple invocations of a method produces a nested OR.

match_gradebook_column_id(gradebook_column_id, match)

Sets the gradebook column Id for this query.

Parameters:
  • gradebook_column_id (osid.id.Id) – a gradeboo column Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgradebook_column_id is null

compliance: mandatory – This method must be implemented.

gradebook_column_id_terms
supports_gradebook_column_query()

Tests if a GradebookColumnQuery is available for querying gradebook column.

Returns:true if a gradebook column query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_column_query

Gets the query for a gradebook column.

Multiple retrievals produce a nested OR term.

Returns:the gradebook column query
Return type:osid.grading.GradebookColumnQuery
Raise:Unimplementedsupports_gradebook_column_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_column_query()`` is ``true``.

match_any_gradebook_column(match)

Matches gradebook column derivations with any gradebookc olumn.

Parameters:match (boolean) – true to match gradebook column derivations with any gradebook column, false to match gradebook column derivations with no gradebook columns

compliance: mandatory – This method must be implemented.

gradebook_column_terms
match_mean(low, high, match)

Matches a mean between the given values inclusive.

Parameters:
  • low (decimal) – low end of range
  • high (decimal) – high end of range
  • match (boolean) – true for a positive match, false for a negative match
Raise:

InvalidArgumentlow is greater than high

compliance: mandatory – This method must be implemented.

mean_terms
match_minimum_mean(value, match)

Matches a mean greater than or equal to the given value.

Parameters:
  • value (decimal) – minimum value
  • match (boolean) – true for a positive match, false for a negative match

compliance: mandatory – This method must be implemented.

minimum_mean_terms
match_median(low, high, match)

Matches a median between the given values inclusive.

Parameters:
  • low (decimal) – low end of range
  • high (decimal) – high end of range
  • match (boolean) – true for a positive match, false for a negative match
Raise:

InvalidArgumentlow is greater than high

compliance: mandatory – This method must be implemented.

median_terms
match_minimum_median(value, match)

Matches a median greater than or equal to the given value.

Parameters:
  • value (decimal) – minimum value
  • match (boolean) – true for a positive match, false for a negative match

compliance: mandatory – This method must be implemented.

minimum_median_terms
match_mode(low, high, match)

Matches a mode between the given values inclusive.

Parameters:
  • low (decimal) – low end of range
  • high (decimal) – high end of range
  • match (boolean) – true for a positive match, false for a negative match
Raise:

InvalidArgumentlow is greater than high

compliance: mandatory – This method must be implemented.

mode_terms
match_minimum_mode(value, match)

Matches a mode greater than or equal to the given value.

Parameters:
  • value (decimal) – minimum value
  • match (boolean) – true for a positive match, false for a negative match

compliance: mandatory – This method must be implemented.

minimum_mode_terms
match_rms(low, high, match)

Matches a root mean square between the given values inclusive.

Parameters:
  • low (decimal) – low end of range
  • high (decimal) – high end of range
  • match (boolean) – true for a positive match, false for a negative match
Raise:

InvalidArgumentlow is greater than high

compliance: mandatory – This method must be implemented.

rms_terms
match_minimum_rms(value, match)

Matches a root mean square greater than or equal to the given value.

Parameters:
  • value (decimal) – minimum value
  • match (boolean) – true for a positive match, false for a negative match

compliance: mandatory – This method must be implemented.

minimum_rms_terms
match_standard_deviation(low, high, match)

Matches a standard deviation mean square between the given values inclusive.

Parameters:
  • low (decimal) – low end of range
  • high (decimal) – high end of range
  • match (boolean) – true for a positive match, false for a negative match
Raise:

InvalidArgumentlow is greater than high

compliance: mandatory – This method must be implemented.

standard_deviation_terms
match_minimum_standard_deviation(value, match)

Matches a standard deviation greater than or equal to the given value.

Parameters:
  • value (decimal) – minimum value
  • match (boolean) – true for a positive match, false for a negative match

compliance: mandatory – This method must be implemented.

minimum_standard_deviation_terms
match_sum(low, high, match)

Matches a sum mean square between the given values inclusive.

Parameters:
  • low (decimal) – low end of range
  • high (decimal) – high end of range
  • match (boolean) – true for a positive match, false for a negative match
Raise:

InvalidArgumentlow is greater than high

compliance: mandatory – This method must be implemented.

sum_terms
match_minimum_sum(value, match)

Matches a sum greater than or equal to the given value.

Parameters:
  • value (decimal) – minimum value
  • match (boolean) – true for a positive match, false for a negative match

compliance: mandatory – This method must be implemented.

minimum_sum_terms
match_gradebook_id(gradebook_id, match)

Sets the gradebook Id for this query.

Parameters:
  • gradebook_id (osid.id.Id) – a gradebook Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgradebook_id is null

compliance: mandatory – This method must be implemented.

gradebook_id_terms
supports_gradebook_query()

Tests if a GradebookQuery is available.

Returns:true if a gradebook query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_query

Gets the query for a gradebook.

Multiple retrievals produce a nested OR term.

Returns:the gradebook query
Return type:osid.grading.GradebookQuery
Raise:Unimplementedsupports_gradebook_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_column_query()`` is ``true``.

gradebook_terms
get_gradebook_column_summary_query_record(gradebook_column_summary_record_type)

Gets the gradebook column summary query record corresponding to the given GradebookColumnSummary record Type.

Multiple retrievals produce a nested OR term.

Parameters:gradebook_column_summary_record_type (osid.type.Type) – a gradebook column summary record type
Returns:the gradebook column summary query record
Return type:osid.grading.records.GradebookColumnSummaryQueryRecord
Raise:NullArgumentgradebook_column_summary_record_type is null
Raise:OperationFailed – unable to complete request
Raise:Unsupportedhas_record_type(gradebook_column_summary_record_type) is false

compliance: mandatory – This method must be implemented.

Gradebook Query

class dlkit.grading.queries.GradebookQuery

Bases: dlkit.osid.queries.OsidCatalogQuery

This is the query for searching gradebooks.

Each method specifies an AND term while multiple invocations of the same method produce a nested OR.

match_grade_system_id(grade_system_id, match)

Sets the grade system Id for this query.

Parameters:
  • grade_system_id (osid.id.Id) – a grade system Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgrade_system_id is null

compliance: mandatory – This method must be implemented.

grade_system_id_terms
supports_grade_system_query()

Tests if a GradeSystemQuery is available.

Returns:true if a grade system query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grade_system_query

Gets the query for a grade system.

Multiple retrievals produce a nested OR term.

Returns:the grade system query
Return type:osid.grading.GradeSystemQuery
Raise:Unimplementedsupports_grade_system_query() is false

compliance: optional – This method must be implemented if ``supports_grade_system_query()`` is ``true``.

match_any_grade_system(match)

Matches gradebooks that have any grade system.

Parameters:match (boolean) – true to match gradebooks with any grade system, false to match gradebooks with no grade system

compliance: mandatory – This method must be implemented.

grade_system_terms
match_grade_entry_id(grade_entry_id, match)

Sets the grade entry Id for this query.

Parameters:
  • grade_entry_id (osid.id.Id) – a grade entry Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgrade_entry_id is null

compliance: mandatory – This method must be implemented.

grade_entry_id_terms
supports_grade_entry_query()

Tests if a GradeEntryQuery is available.

Returns:true if a grade entry query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

grade_entry_query

Gets the query for a grade entry.

Multiple retrievals produce a nested OR term.

Returns:the grade entry query
Return type:osid.grading.GradeEntryQuery
Raise:Unimplementedsupports_grade_entry_query() is false

compliance: optional – This method must be implemented if ``supports_grade_entry_query()`` is ``true``.

match_any_grade_entry(match)

Matches gradebooks that have any grade entry.

Parameters:match (boolean) – true to match gradebooks with any grade entry, false to match gradebooks with no grade entry

compliance: mandatory – This method must be implemented.

grade_entry_terms
match_gradebook_column_id(gradebook_column_id, match)

Sets the gradebook column Id for this query.

Parameters:
  • gradebook_column_id (osid.id.Id) – a gradebook column Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgradebook_column_id is null

compliance: mandatory – This method must be implemented.

gradebook_column_id_terms
supports_gradebook_column_query()

Tests if a GradebookColumnQuery is available.

Returns:true if a gradebook column query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

gradebook_column_query

Gets the query for a gradebook column.

Multiple retrievals produce a nested OR term.

Returns:the gradebook column query
Return type:osid.grading.GradebookColumnQuery
Raise:Unimplementedsupports_gradebook_column_query() is false

compliance: optional – This method must be implemented if ``supports_gradebook_column_query()`` is ``true``.

match_any_gradebook_column(match)

Matches gradebooks that have any column.

Parameters:match (boolean) – true to match gradebooks with any column, false to match gradebooks with no column

compliance: mandatory – This method must be implemented.

gradebook_column_terms
match_ancestor_gradebook_id(gradebook_id, match)

Sets the gradebook Id for this query to match gradebooks that have the specified gradebook as an ancestor.

Parameters:
  • gradebook_id (osid.id.Id) – a gradebook Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgradebook_id is null

compliance: mandatory – This method must be implemented.

ancestor_gradebook_id_terms
supports_ancestor_gradebook_query()

Tests if a GradebookQuery is available.

Returns:true if a gradebook query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

ancestor_gradebook_query

Gets the query for a gradebook.

Multiple retrievals produce a nested OR term.

Returns:the gradebook query
Return type:osid.grading.GradebookQuery
Raise:Unimplementedsupports_ancestor_gradebook_query() is false

compliance: optional – This method must be implemented if ``supports_ancestor_gradebook_query()`` is ``true``.

match_any_ancestor_gradebook(match)

Matches gradebook with any ancestor.

Parameters:match (boolean) – true to match gradebooks with any ancestor, false to match root gradebooks

compliance: mandatory – This method must be implemented.

ancestor_gradebook_terms
match_descendant_gradebook_id(gradebook_id, match)

Sets the gradebook Id for this query to match gradebooks that have the specified gradebook as a descendant.

Parameters:
  • gradebook_id (osid.id.Id) – a gradebook Id
  • match (boolean) – true for a positive match, false for a negative match
Raise:

NullArgumentgradebook_id is null

compliance: mandatory – This method must be implemented.

descendant_gradebook_id_terms
supports_descendant_gradebook_query()

Tests if a GradebookQuery is available.

Returns:true if a gradebook query is available, false otherwise
Return type:boolean

compliance: mandatory – This method must be implemented.

descendant_gradebook_query

Gets the query for a gradebook.

Multiple retrievals produce a nested OR term.

Returns:the gradebook query
Return type:osid.grading.GradebookQuery
Raise:Unimplementedsupports_descendant_gradebook_query() is false

compliance: optional – This method must be implemented if ``supports_descendant_gradebook_query()`` is ``true``.

match_any_descendant_gradebook(match)

Matches gradebook with any descendant.

Parameters:match (boolean) – true to match gradebooks with any descendant, false to match leaf gradebooks

compliance: mandatory – This method must be implemented.

descendant_gradebook_terms
get_gradebook_query_record(gradebook_record_type)

Gets the gradebook query record corresponding to the given Gradebook record Type.

Multiple record retrievals produce a nested OR term.

Parameters:gradebook_record_type (osid.type.Type) – a gradebook record type
Returns:the gradebook query record
Return type:osid.grading.records.GradebookQueryRecord
Raise:NullArgumentgradebook_record_type is null
Raise:OperationFailed – unable to complete request
Raise:Unsupportedhas_record_type(gradebook_record_type) is false

compliance: mandatory – This method must be implemented.