Class CriteriaStore

  • All Implemented Interfaces:
    Store

    public class CriteriaStore
    extends java.lang.Object
    implements Store
    Used to store the results from a query made on a QueryService
    • Method Summary

      Modifier and Type Method Description
      void awaitCompletion()
      Wait indefinitely for search to complete unless interrupted.
      boolean awaitCompletion​(long timeout, java.util.concurrent.TimeUnit unit)
      Wait for search to complete unless interrupted or the wait timeout is exceeded.
      void destroy()
      Stop searching and destroy any stored data.
      Data getData​(java.lang.String componentId)
      Get the current data that is available for the specified component.
      Sizes getDefaultMaxResultsSizes()
      Get a list of the default maximum result row counts for each grouping level, e.g.
      java.util.List<java.lang.String> getErrors()
      Gets a list of strings containing all errors that have occurred so far during the current search.
      java.util.List<java.lang.String> getHighlights()
      Get any search query highlights that can be extracted from the query.
      Sizes getStoreSize()
      Get the store size configuration for this store
      boolean isComplete()
      Find out if the search has completed.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • destroy

        public void destroy()
        Description copied from interface: Store
        Stop searching and destroy any stored data.
        Specified by:
        destroy in interface Store
      • isComplete

        public boolean isComplete()
        Description copied from interface: Store
        Find out if the search has completed. There will be no new results once complete so we can stop requesting updates.
        Specified by:
        isComplete in interface Store
        Returns:
        True if the search has completed.
      • awaitCompletion

        public void awaitCompletion()
        Description copied from interface: Store
        Wait indefinitely for search to complete unless interrupted.
        Specified by:
        awaitCompletion in interface Store
      • awaitCompletion

        public boolean awaitCompletion​(long timeout,
                                       java.util.concurrent.TimeUnit unit)
        Description copied from interface: Store
        Wait for search to complete unless interrupted or the wait timeout is exceeded.
        Specified by:
        awaitCompletion in interface Store
        Parameters:
        timeout - The timeout.
        unit - The unit of the timeout.
        Returns:
        True if search completed.
      • getData

        public Data getData​(java.lang.String componentId)
        Description copied from interface: Store
        Get the current data that is available for the specified component.
        Specified by:
        getData in interface Store
        Parameters:
        componentId - The id of the component that results are being populated for.
        Returns:
        A store of current search results for the specified component.
      • getErrors

        public java.util.List<java.lang.String> getErrors()
        Description copied from interface: Store
        Gets a list of strings containing all errors that have occurred so far during the current search.
        Specified by:
        getErrors in interface Store
        Returns:
        A string containing all errors that have occurred so far during the current search.
      • getHighlights

        public java.util.List<java.lang.String> getHighlights()
        Description copied from interface: Store
        Get any search query highlights that can be extracted from the query.
        Specified by:
        getHighlights in interface Store
        Returns:
        A set of strings found in the query that could be highlighted in the UI to show where the query terms have been found.
      • getDefaultMaxResultsSizes

        public Sizes getDefaultMaxResultsSizes()
        Description copied from interface: Store
        Get a list of the default maximum result row counts for each grouping level, e.g. [100,10,1] means at most 100 rows for group level 0, 10 for each group level 1 and 1 for each group level 2
        Specified by:
        getDefaultMaxResultsSizes in interface Store
        Returns:
        A list of Integer values, where the value represents the default maximum number of results at a grouping depth equal to the position in the list
      • getStoreSize

        public Sizes getStoreSize()
        Description copied from interface: Store
        Get the store size configuration for this store
        Specified by:
        getStoreSize in interface Store
        Returns:
        A non-null Sizes object