Module org.apache.lucene.monitor
Package org.apache.lucene.monitor
Record Class ParallelMatcher.ParallelMatcherFactory<T extends QueryMatch>
java.lang.Object
java.lang.Record
org.apache.lucene.monitor.ParallelMatcher.ParallelMatcherFactory<T>
- All Implemented Interfaces:
MatcherFactory<T>
- Enclosing class:
ParallelMatcher<T extends QueryMatch>
private static record ParallelMatcher.ParallelMatcherFactory<T extends QueryMatch>(ExecutorService executor, MatcherFactory<T extends QueryMatch> matcherFactory, int threads)
extends Record
implements MatcherFactory<T>
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ExecutorServiceThe field for theexecutorrecord component.private final MatcherFactory<T> The field for thematcherFactoryrecord component.private final intThe field for thethreadsrecord component. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateParallelMatcherFactory(ExecutorService executor, MatcherFactory<T> matcherFactory, int threads) Creates an instance of aParallelMatcherFactoryrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncreateMatcher(IndexSearcher searcher) Create a newCandidateMatcherobject, to select queries to match against the passed-in IndexSearcherfinal booleanIndicates whether some other object is "equal to" this one.executor()Returns the value of theexecutorrecord component.final inthashCode()Returns a hash code value for this object.Returns the value of thematcherFactoryrecord component.intthreads()Returns the value of thethreadsrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
executor
The field for theexecutorrecord component. -
matcherFactory
The field for thematcherFactoryrecord component. -
threads
private final int threadsThe field for thethreadsrecord component.
-
-
Constructor Details
-
ParallelMatcherFactory
private ParallelMatcherFactory(ExecutorService executor, MatcherFactory<T> matcherFactory, int threads) Creates an instance of aParallelMatcherFactoryrecord class.- Parameters:
executor- the value for theexecutorrecord componentmatcherFactory- the value for thematcherFactoryrecord componentthreads- the value for thethreadsrecord component
-
-
Method Details
-
createMatcher
Description copied from interface:MatcherFactoryCreate a newCandidateMatcherobject, to select queries to match against the passed-in IndexSearcher- Specified by:
createMatcherin interfaceMatcherFactory<T extends QueryMatch>
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
executor
Returns the value of theexecutorrecord component.- Returns:
- the value of the
executorrecord component
-
matcherFactory
Returns the value of thematcherFactoryrecord component.- Returns:
- the value of the
matcherFactoryrecord component
-
threads
public int threads()Returns the value of thethreadsrecord component.- Returns:
- the value of the
threadsrecord component
-