Interface RelevancySmartOntologySession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface RelevancySmartOntologySession extends OsidSession

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

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

  • 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.
    • getRelevancyQuery

      RelevancyQuery getRelevancyQuery()
      Gets a relevancy query.
      Returns:
      the relevancy query
      Compliance:
      mandatory - This method must be implemented.
    • getRelevancySearchOrder

      RelevancySearchOrder getRelevancySearchOrder()
      Gets a relevancy search order.
      Returns:
      the relevancy search order
      Compliance:
      mandatory - This method must be implemented.
    • applyRelevancyQuery

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

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

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

      RelevancyQuery getRelevancyQueryFromInspector(RelevancyQueryInspector relevancyQueryInspector)
      Gets a relevancy query from an inspector.
      Parameters:
      relevancyQueryInspector - a relevancy query inspector
      Returns:
      the relevancy query
      Throws:
      NullArgumentException - relevancyQueryInspector is null
      UnsupportedException - relevancyQueryInspector is not of this service
      Compliance:
      mandatory - This method must be implemented.