Interface ParallelLinearRetriever<TCase extends DataObject,TQuery extends Query>

All Superinterfaces:
Retriever<DataObject,Query>
All Known Implementing Classes:
ParallelLinearRetrieverImpl

public interface ParallelLinearRetriever<TCase extends DataObject,TQuery extends Query> extends Retriever<DataObject,Query>
Interface for a parallelized LinearRetriever.
  • Field Details

    • DEFAULT_SORTING

      static final boolean DEFAULT_SORTING
      Default value, if queue should be sorted before retrieval, is false.
      See Also:
    • DEFAULT_TASK_SIZE

      static final int DEFAULT_TASK_SIZE
      Default size for retrieval tasks is 1.
      See Also:
    • DEFAULT_NUMBER_OF_WORKERS

      static final int DEFAULT_NUMBER_OF_WORKERS
      Default number of worker threads is the number of CPU cores
  • Method Details

    • setNumberOfWorkers

      void setNumberOfWorkers(int numberOfWorkers)
      Set the number of parallel worker threads performing retrieval tasks
      Parameters:
      numberOfWorkers - number of parallel retrieval tasks
    • getNumberOfWorkers

      int getNumberOfWorkers()
      Returns:
      number of workers
    • setTaskSize

      void setTaskSize(int taskSize)
      Sets the size of a single retrieval task.
      Parameters:
      taskSize - size of a single retrieval task
    • getTaskSize

      int getTaskSize()
      Returns:
      size of a single retrieval task
    • setSorting

      void setSorting(boolean sorting)
      Determines whether queue should be sorted before retrieval or not.
      Parameters:
      sorting - true, if queue should be sorted before retrieval
    • isSorting

      boolean isSorting()
      Returns:
      flag, if queue should be sorted before retrieval