Interface ProfileItemSearchSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession, ProfileItemQuerySession

public interface ProfileItemSearchSession extends ProfileItemQuerySession

This session provides methods for searching ProfileItems . The search query is constructed using the ProfileItemQuery . The profile item record Type also specifies the query record for the profile item query.

getProfileItemsByQuery() is the basic search method and returns a list of ProfileItems . A more advanced search may be performed with getProfileItemsBySearch() .It accepts a ProfileItemSearch in addition to the query for the purpose of specifying additional options affecting the entire search, such as ordering. getProfileItemsBySearch() returns an ProfileItemSearchResults that can be used to access the resulting ProfileItemList or be used to perform a search within the result set through ProfileItemSearch .

This session defines views that offer differing behaviors for searching.

  • federated profile view: searches include profile item in profiles of which this profile is an ancestor in the profile hierarchy
  • isolated profile view: searches are restricted to profile items in this profile

Profile items may have a profie item query record indicated by their respective record types. The profile item query record is accessed via the ProfileItemQuery .

  • Method Details

    • getProfileItemSearch

      ProfileItemSearch getProfileItemSearch()
      Gets a profile item search.
      Returns:
      the profile item search
      Compliance:
      mandatory - This method must be implemented.
    • getProfileItemSearchOrder

      ProfileItemSearchOrder getProfileItemSearchOrder()
      Gets a profile item search order. The ProfileItemSearchOrder is supplied to a ProfileItemSearch to specify the ordering of results.
      Returns:
      the profile item search order
      Compliance:
      mandatory - This method must be implemented.
    • getProfileItemsBySearch

      ProfileItemSearchResults getProfileItemsBySearch(ProfileItemQuery profileItemQuery, ProfileItemSearch profileItemSearch) throws OperationFailedException, PermissionDeniedException
      Gets the search results matching the given search query using the given search.
      Parameters:
      profileItemQuery - the profile item query
      profileItemSearch - the profile item search
      Returns:
      the returned search results
      Throws:
      NullArgumentException - profileItemQuery or profileItemSearch is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      UnsupportedException - profileItemSearch or profileItemQuery is not of this service
      Compliance:
      mandatory - This method must be implemented.
    • getProfileItemQueryFromInspector

      ProfileItemQuery getProfileItemQueryFromInspector(ProfileItemQueryInspector profileItemQueryInspector)
      Gets a profile item query from an inspector. The inspector is available from an ProfileItemSearchResults .
      Parameters:
      profileItemQueryInspector - a profile item query inspector
      Returns:
      the profile item query
      Throws:
      NullArgumentException - profileItemQueryInspector is null
      UnsupportedException - profileItemQueryInspector is not of this service
      Compliance:
      mandatory - This method must be implemented.