Interface DocumentSearchService

All Known Implementing Classes:
DocumentSearchServiceImpl

public interface DocumentSearchService
Service for data access for document searches.
Author:
Kuali Rice Team (rice.collab@kuali.org)
  • Method Summary

    Modifier and Type
    Method
    Description
    org.kuali.rice.kew.api.document.search.DocumentSearchCriteria
    clearCriteria(DocumentType documentType, org.kuali.rice.kew.api.document.search.DocumentSearchCriteria criteria)
     
    void
    Clears all saved searches for the specified user (named and automatic)
    int
    Returns the number of results that should be returned from an additional fetch against the document search.
    int
    getMaxResultCap(org.kuali.rice.kew.api.document.search.DocumentSearchCriteria criteria)
    Returns the maximum number of results that should be returned from the document search.
    List<org.kuali.rice.core.api.util.KeyValue>
    Returns automatically saved recent searches for the specified user
    org.kuali.rice.kew.api.document.search.DocumentSearchCriteria
    getNamedSearchCriteria(String principalId, String savedSearchName)
    Returns an explicitly named saved search criteria
    List<org.kuali.rice.core.api.util.KeyValue>
    getNamedSearches(String principalId)
    Returns named saved searches for the specified user
    org.kuali.rice.kew.api.document.search.DocumentSearchCriteria
    Returns a saved search criteria, either explicitly named by the user, or saved automatically as a recent search
     
    org.kuali.rice.kew.api.document.search.DocumentSearchResults
    lookupDocuments(String principalId, org.kuali.rice.kew.api.document.search.DocumentSearchCriteria criteria)
    This method performs a standard document search for the given criteria.
    org.kuali.rice.kew.api.document.search.DocumentSearchResults
    lookupDocuments(String principalId, org.kuali.rice.kew.api.document.search.DocumentSearchCriteria criteria, boolean saveSearch)
    This method performs a standard document search for the given criteria.
    void
    validateDocumentSearchCriteria(DocumentSearchGenerator docSearchGenerator, org.kuali.rice.kew.api.document.search.DocumentSearchCriteria.Builder criteria)
     
  • Method Details

    • lookupDocuments

      org.kuali.rice.kew.api.document.search.DocumentSearchResults lookupDocuments(String principalId, org.kuali.rice.kew.api.document.search.DocumentSearchCriteria criteria)
      This method performs a standard document search for the given criteria.
      Parameters:
      principalId - the id of the principal who is executing the search, this may be null to indicate the search could be executed by an arbitrary user
      criteria - criteria to use to search documents
      Returns:
      the results of the search, will never return null
    • lookupDocuments

      org.kuali.rice.kew.api.document.search.DocumentSearchResults lookupDocuments(String principalId, org.kuali.rice.kew.api.document.search.DocumentSearchCriteria criteria, boolean saveSearch)
      This method performs a standard document search for the given criteria.
      Parameters:
      principalId - the id of the principal who is executing the search, this may be null to indicate the search could be executed by an arbitrary user
      criteria - criteria to use to search documents
      boolean - to indicate if search criteria should be saved to the users preferences
      Returns:
      the results of the search, will never return null
    • getSavedSearchCriteria

      org.kuali.rice.kew.api.document.search.DocumentSearchCriteria getSavedSearchCriteria(String principalId, String key)
      Returns a saved search criteria, either explicitly named by the user, or saved automatically as a recent search
      Parameters:
      principalId - the user principal id
      key - the user option key under which the criteria is saved
      Returns:
      the DocumentSearchCriteria or null if not found
    • getNamedSearchCriteria

      org.kuali.rice.kew.api.document.search.DocumentSearchCriteria getNamedSearchCriteria(String principalId, String savedSearchName)
      Returns an explicitly named saved search criteria
      Parameters:
      principalId - the user principal id
      savedSearchName - the user-provided saved search name
      Returns:
      the DocumentSearchCriteria or null if not found
    • clearNamedSearches

      void clearNamedSearches(String principalId)
      Clears all saved searches for the specified user (named and automatic)
      Parameters:
      principalId - user principal id
    • getNamedSearches

      List<org.kuali.rice.core.api.util.KeyValue> getNamedSearches(String principalId)
      Returns named saved searches for the specified user
      Parameters:
      principalId - the user principal id
      Returns:
      list of search key/label
    • getMostRecentSearches

      List<org.kuali.rice.core.api.util.KeyValue> getMostRecentSearches(String principalId)
      Returns automatically saved recent searches for the specified user
      Parameters:
      principalId - the user principal id
      Returns:
      list of search key/label
    • clearCriteria

      org.kuali.rice.kew.api.document.search.DocumentSearchCriteria clearCriteria(DocumentType documentType, org.kuali.rice.kew.api.document.search.DocumentSearchCriteria criteria)
    • getStandardDocumentSearchGenerator

      DocumentSearchGenerator getStandardDocumentSearchGenerator()
    • validateDocumentSearchCriteria

      void validateDocumentSearchCriteria(DocumentSearchGenerator docSearchGenerator, org.kuali.rice.kew.api.document.search.DocumentSearchCriteria.Builder criteria)
    • getMaxResultCap

      int getMaxResultCap(org.kuali.rice.kew.api.document.search.DocumentSearchCriteria criteria)
      Returns the maximum number of results that should be returned from the document search.
      Parameters:
      criteria - the criteria in which to check for a max results value
      Returns:
      the maximum number of results that should be returned from a document search
    • getFetchMoreIterationLimit

      int getFetchMoreIterationLimit()
      Returns the number of results that should be returned from an additional fetch against the document search. Default:
      invalid reference
      org.kuali.rice.kew.docsearch.dao.impl.DocumentSearchDAOJdbcImpl.DEFAULT_FETCH_MORE_ITERATION_LIMIT
      Override: KewApiConstants.DOC_SEARCH_FETCH_MORE_ITERATION_LIMIT
      Returns:
      int