OSID Logo
OSID Specifications
ontology package
Version 3.1.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.

Parametersstringcode the code string
osid.type.TypestringMatchType a string match type
booleanmatch true for a positive match, false for a negative match
ErrorsNULL_ARGUMENT code or stringMatchType is null
Compliancemandatory This method must be implemented.
MethodclearCodeTerms
Description

Clears the code terms.

Compliancemandatory This 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.IdsubjectId a subject Id
booleanmatch true for a positive match, false for a negative match
ErrorsNULL_ARGUMENT subjectId is null
Compliancemandatory This method must be implemented.
MethodclearAncestorSubjectIdTerms
Description

Clears the ancestor subject Id terms for this query.

Compliancemandatory This method must be implemented.
MethodsupportsAncestorSubjectQuery
Description

Tests if a SubjectQuery is available.

Returnboolean true if a subject query is available, false otherwise
Compliancemandatory This method must be implemented.
MethodgetAncestorSubjectQuery
Description

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

Returnosid.ontology.SubjectQuery the subject query
ErrorsUNIMPLEMENTED supportsAncestorSubjectQuery() is false
Complianceoptional This method must be implemented if supportsAncestorSubjectQuery() is true.
MethodmatchAnyAncestorSubject
Description

Matches subjects with any ancestor.

Parametersbooleanmatch true to match subjects with any ancestor, false to match root subjects
Compliancemandatory This method must be implemented.
MethodclearAncestorSubjectTerms
Description

Clears the ancestor subject terms for this query.

Compliancemandatory This 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.IdsubjectId a subject Id
booleanmatch true for a positive match, false for a negative match
ErrorsNULL_ARGUMENT subjectId is null
Compliancemandatory This method must be implemented.
MethodclearDescendantSubjectIdTerms
Description

Clears the descendant subject Id terms for this query.

Compliancemandatory This method must be implemented.
MethodsupportsDescendantSubjectQuery
Description

Tests if a SubjectQuery is available.

Returnboolean true if a subject query is available, false otherwise
Compliancemandatory This method must be implemented.
MethodgetDescendantSubjectQuery
Description

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

Returnosid.ontology.SubjectQuery the subject query
ErrorsUNIMPLEMENTED supportsDescendantSubjectQuery() is false
Complianceoptional This method must be implemented if supportsDescendantSubjectQuery() is true.
MethodmatchAnyDescendantSubject
Description

Matches subjects with any descendant.

Parametersbooleanmatch true to match subjects with any descendant, false to match leaf subjects
Compliancemandatory This method must be implemented.
MethodclearDescendantSubjectTerms
Description

Clears the descendant subject terms for this query.

Compliancemandatory This method must be implemented.
MethodmatchRelevancyId
Description

Sets the relevancy Id for this query.

Parametersosid.id.IdrelevancyId a relevancy Id
booleanmatch true for a positive match, false for a negative match
ErrorsNULL_ARGUMENT relevancyId is null
Compliancemandatory This method must be implemented.
MethodclearRelevancyIdTerms
Description

Clears the relevancy Id terms for this query.

Compliancemandatory This method must be implemented.
MethodsupportsRelevancyQuery
Description

Tests if a RelevancyQuery is available.

Returnboolean true if a relevancy query is available, false otherwise
Compliancemandatory This method must be implemented.
MethodgetRelevancyQuery
Description

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

Returnosid.ontology.RelevancyQuery the relevancy query
ErrorsUNIMPLEMENTED supportsRelevancyQuery() is false
Complianceoptional This method must be implemented if supportsRelevancyQuery() is true.
MethodmatchAnyRelevancy
Description

Matches ontologies that have any relevancy.

Parametersbooleanmatch true to match ontologies with any relevancy, false to match ontologies with no relevancy
Compliancemandatory This method must be implemented.
MethodclearRelevancyTerms
Description

Clears the relevancy terms for this query.

Compliancemandatory This method must be implemented.
MethodmatchOntologyId
Description

Sets the ontology Id for this query.

Parametersosid.id.IdontologyId an ontology Id
booleanmatch true for a positive match, false for a negative match
ErrorsNULL_ARGUMENT ontologyId is null
Compliancemandatory This method must be implemented.
MethodclearOntologyIdTerms
Description

Clears the ontology Id terms for this query.

Compliancemandatory This method must be implemented.
MethodsupportsOntologyQuery
Description

Tests if an OntologyQuery is available for querying ontologies.

Returnboolean true if an ontology query is available, false otherwise
Compliancemandatory This method must be implemented.
MethodgetOntologyQuery
Description

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

Returnosid.ontology.OntologyQuery the ontology query
ErrorsUNIMPLEMENTED supportsOntologyQuery() is false
Complianceoptional This method must be implemented if supportsOntologyQuery() is true.
MethodclearOntologyTerms
Description

Clears the ontology terms for this query.

Compliancemandatory This 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.TypesubjectRecordType a subject query record type
Returnosid.ontology.records.SubjectQueryRecord the subject query record
ErrorsNULL_ARGUMENT subjectRecordType is null
OPERATION_FAILED unable to complete request
UNSUPPORTED hasRecordType(subjectRecordType) is false
Compliancemandatory This method must be implemented.