Interface SubjectSmartOntologySession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface SubjectSmartOntologySession extends OsidSession

This session manages queries and sequencing to create "smart" dynamic catalogs. A SubjectQuery can be retrieved from this session and mapped to this Ontology to create a virtual collection of Subjects . The entries may be sequenced using the SubjectSearchOrder from this session.

This Ontology has a default query that matches any subject and a default search order that specifies no sequencing. The queries may be examined using a SubjectQueryInspector . The query may be modified by converting the inspector back to a SubjectQuery .

  • Method Details

    • getOntologyId

      Id getOntologyId()
      Gets the Ontology Id associated with this session.
      Returns:
      the Ontology Id associated with this session
      Compliance:
      mandatory - This method must be implemented.
    • getOntology

      Gets the Ontology associated with this session.
      Returns:
      the Ontology associated with this session
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • canManageSmartOntologies

      boolean canManageSmartOntologies()
      Tests if this user can manage smart ontologies. 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 PERMISSION_DENIED . This is intended as a hint to an application that may opt not to offer smart operations.
      Returns:
      false if smart ontology methods are not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getSubjectQuery

      SubjectQuery getSubjectQuery()
      Gets a subject query.
      Returns:
      the subject query
      Compliance:
      mandatory - This method must be implemented.
    • getSubjectSearchOrder

      SubjectSearchOrder getSubjectSearchOrder()
      Gets a subject search order.
      Returns:
      the subject search order
      Compliance:
      mandatory - This method must be implemented.
    • applySubjectQuery

      void applySubjectQuery(SubjectQuery subjectQuery) throws OperationFailedException, PermissionDeniedException
      Applies a subject query to this ontology.
      Parameters:
      subjectQuery - the subject query
      Throws:
      NullArgumentException - subjectQuery is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure occurred
      UnsupportedException - subjectQuery not of this service
      Compliance:
      mandatory - This method must be implemented.
    • inspectSubjectQuery

      Gets a subject query inspector for this ontology.
      Returns:
      the subject query inspector
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure occurred
      Compliance:
      mandatory - This method must be implemented.
    • applySubjectSequencing

      void applySubjectSequencing(SubjectSearchOrder subjectSearchOrder) throws OperationFailedException, PermissionDeniedException
      Applies a subject search order to this ontology.
      Parameters:
      subjectSearchOrder - the subject search order
      Throws:
      NullArgumentException - subjectSearchOrder is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure occurred
      UnsupportedException - subjectSearchOrder not of this service
      Compliance:
      mandatory - This method must be implemented.
    • getSubjectQueryFromInspector

      SubjectQuery getSubjectQueryFromInspector(SubjectQueryInspector subjectQueryInspector)
      Gets a subject query from an inspector.
      Parameters:
      subjectQueryInspector - a subject query inspector
      Returns:
      the subject query
      Throws:
      NullArgumentException - subjectQueryInspector is null
      UnsupportedException - subjectQueryInspector is not of this service
      Compliance:
      mandatory - This method must be implemented.