Interface CustomerSearchSession

All Superinterfaces:
AutoCloseable, Closeable, CustomerQuerySession, OsidSession, OsidSession

public interface CustomerSearchSession extends CustomerQuerySession

This session provides methods for searching among Customers . The search query is constructed using the CustomerQuery .

getCustomersByQuery() is the basic search method and returns a list of Customers . A more advanced search may be performed with getCustomersBySearch() .It accepts a CustomerSearch in addition to the query for the purpose of specifying additional options affecting the entire search, such as ordering. getCustomersBySearch() returns a CustomerSearchResults that can be used to access the resulting CustomerList or be used to perform a search within the result set through CustomerSearch .

This session defines views that offer differing behaviors for searching.

  • federated business view: searches include customers in businesses of which this business is an ancestor in the business hierarchy
  • isolated business view: searches are restricted to customers in this business

Customers may have a query record indicated by their respective record types. The query record is accessed via the CustomerQuery .

  • Method Details

    • getCustomerSearch

      CustomerSearch getCustomerSearch()
      Gets a customer search.
      Returns:
      the customer search
      Compliance:
      mandatory - This method must be implemented.
    • getCustomerSearchOrder

      CustomerSearchOrder getCustomerSearchOrder()
      Gets a customer search order. The CustomerSearchOrder is supplied to a CustomerSearch to specify the ordering of results.
      Returns:
      the customer search order
      Compliance:
      mandatory - This method must be implemented.
    • getCustomersBySearch

      CustomerSearchResults getCustomersBySearch(CustomerQuery customerQuery, CustomerSearch customerSearch) throws OperationFailedException, PermissionDeniedException
      Gets the search results matching the given search query using the given search.
      Parameters:
      customerQuery - the customer query
      customerSearch - the customer search
      Returns:
      the customer search results
      Throws:
      NullArgumentException - customerQuery or customerSearch is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      UnsupportedException - customerQuery or customerSearch is not of this service
      Compliance:
      mandatory - This method must be implemented.
    • getCustomerQueryFromInspector

      CustomerQuery getCustomerQueryFromInspector(CustomerQueryInspector customerQueryInspector)
      Gets a customer query from an inspector. The inspector is available from a CustomerSearchResults .
      Parameters:
      customerQueryInspector - a customer query inspector
      Returns:
      the customer query
      Throws:
      NullArgumentException - customerQueryInspector is null
      UnsupportedException - customerQueryInspector is not of this service
      Compliance:
      mandatory - This method must be implemented.