OSID Logo
OSID Specifications
ontology package
Version 3.0.0
Interfaceosid.ontology.SubjectQuery
Implementsosid.OsidObjectQuery
osid.OsidFederateableQuery
Used Byosid.OsidObjectQuery
osid.course.requisite.CourseRequirementQuery
osid.ontology.OntologyQuery
osid.ontology.RelevancyQuery
osid.ontology.SubjectQuery
osid.ontology.SubjectQuerySession
osid.ontology.SubjectSearchSession
osid.ontology.SubjectSmartOntologySession
osid.tracking.IssueQuery
Description

This is the query for searching subjects. Each method match request produces an AND term while multiple invocations of a method produces a nested OR .

MethodmatchCode
Description

Matches the subject code.

Parametersstringcodethe code string
osid.type.TypestringMatchTypea string match type
booleanmatchtrue for a positive match, false for a negative match
ErrorsNULL_ARGUMENTcode or stringMatchType is null
CompliancemandatoryThis method must be implemented.
MethodclearCodeTerms
Description

Clears the code terms.

CompliancemandatoryThis method must be implemented.
MethodmatchAncestorSubjectId
Description

Sets the subject Id for this query to match subjects that have the specified subject as an ancestor.

Parametersosid.id.IdsubjectIda subject Id
booleanmatchtrue for a positive match, false for a negative match
ErrorsNULL_ARGUMENTsubjectId is null
CompliancemandatoryThis method must be implemented.
MethodclearAncestorSubjectIdTerms
Description

Clears the ancestor subject Id terms for this query.

CompliancemandatoryThis method must be implemented.
MethodsupportsAncestorSubjectQuery
Description

Tests if a SubjectQuery is available.

Returnbooleantrue if a subject query is available, false otherwise
CompliancemandatoryThis method must be implemented.
MethodgetAncestorSubjectQuery
Description

Gets the query for a subject. Multiple retrievals produce a nested OR term.

Returnosid.ontology.SubjectQuerythe subject query
ErrorsUNIMPLEMENTEDsupportsAncestorSubjectQuery() is false
ComplianceoptionalThis method must be implemented if supportsAncestorSubjectQuery() is true .
MethodmatchAnyAncestorSubject
Description

Matches subjects with any ancestor.

Parametersbooleanmatchtrue to match subjects with any ancestor, false to match root subjects
CompliancemandatoryThis method must be implemented.
MethodclearAncestorSubjectTerms
Description

Clears the ancestor subject terms for this query.

CompliancemandatoryThis method must be implemented.
MethodmatchDescendantSubjectId
Description

Sets the subject Id for this query to match subjects that have the specified subject as a descendant.

Parametersosid.id.IdsubjectIda subject Id
booleanmatchtrue for a positive match, false for a negative match
ErrorsNULL_ARGUMENTsubjectId is null
CompliancemandatoryThis method must be implemented.
MethodclearDescendantSubjectIdTerms
Description

Clears the descendant subject Id terms for this query.

CompliancemandatoryThis method must be implemented.
MethodsupportsDescendantSubjectQuery
Description

Tests if a SubjectQuery is available.

Returnbooleantrue if a subject query is available, false otherwise
CompliancemandatoryThis method must be implemented.
MethodgetDescendantSubjectQuery
Description

Gets the query for a subject. Multiple retrievals produce a nested OR term.

Returnosid.ontology.SubjectQuerythe subject query
ErrorsUNIMPLEMENTEDsupportsDescendantSubjectQuery() is false
ComplianceoptionalThis method must be implemented if supportsDescendantSubjectQuery() is true .
MethodmatchAnyDescendantSubject
Description

Matches subjects with any descendant.

Parametersbooleanmatchtrue to match subjects with any descendant, false to match leaf subjects
CompliancemandatoryThis method must be implemented.
MethodclearDescendantSubjectTerms
Description

Clears the descendant subject terms for this query.

CompliancemandatoryThis method must be implemented.
MethodmatchRelevancyId
Description

Sets the relevancy Id for this query.

Parametersosid.id.IdrelevancyIda relevancy Id
booleanmatchtrue for a positive match, false for a negative match
ErrorsNULL_ARGUMENTrelevancyId is null
CompliancemandatoryThis method must be implemented.
MethodclearRelevancyIdTerms
Description

Clears the relevancy Id terms for this query.

CompliancemandatoryThis method must be implemented.
MethodsupportsRelevancyQuery
Description

Tests if a RelevancyQuery is available.

Returnbooleantrue if a relevancy query is available, false otherwise
CompliancemandatoryThis method must be implemented.
MethodgetRelevancyQuery
Description

Gets the query for a relevancy. Multiple retrievals produce a nested OR term.

Returnosid.ontology.RelevancyQuerythe relevancy query
ErrorsUNIMPLEMENTEDsupportsRelevancyQuery() is false
ComplianceoptionalThis method must be implemented if supportsRelevancyQuery() is true .
MethodmatchAnyRelevancy
Description

Matches ontologies that have any relevancy.

Parametersbooleanmatchtrue to match ontologies with any relevancy, false to match ontologies with no relevancy
CompliancemandatoryThis method must be implemented.
MethodclearRelevancyTerms
Description

Clears the relevancy terms for this query.

CompliancemandatoryThis method must be implemented.
MethodmatchOntologyId
Description

Sets the ontology Id for this query.

Parametersosid.id.IdontologyIdan ontology Id
booleanmatchtrue for a positive match, false for a negative match
ErrorsNULL_ARGUMENTontologyId is null
CompliancemandatoryThis method must be implemented.
MethodclearOntologyIdTerms
Description

Clears the ontology Id terms for this query.

CompliancemandatoryThis method must be implemented.
MethodsupportsOntologyQuery
Description

Tests if an OntologyQuery is available for querying ontologies.

Returnbooleantrue if an ontology query is available, false otherwise
CompliancemandatoryThis method must be implemented.
MethodgetOntologyQuery
Description

Gets the query for an ontology. Multiple retrievals produce a nested OR term.

Returnosid.ontology.OntologyQuerythe ontology query
ErrorsUNIMPLEMENTEDsupportsOntologyQuery() is false
ComplianceoptionalThis method must be implemented if supportsOntologyQuery() is true .
MethodclearOntologyTerms
Description

Clears the ontology terms for this query.

CompliancemandatoryThis method must be implemented.
MethodgetSubjectQueryRecord
Description

Gets the subject query record corresponding to the given Subject record Type .Multiple retrievals produce a nested OR term.

Parametersosid.type.TypesubjectRecordTypea subject query record type
Returnosid.ontology.records.SubjectQueryRecordthe subject query record
ErrorsNULL_ARGUMENTsubjectRecordType is null
OPERATION_FAILEDunable to complete request
UNSUPPORTEDhasRecordType(subjectRecordType) is false
CompliancemandatoryThis method must be implemented.