Class InternalProfileCollector
- java.lang.Object
-
- org.elasticsearch.search.profile.query.InternalProfileCollector
-
- All Implemented Interfaces:
Collector
public class InternalProfileCollector extends Object implements Collector
This class wraps a Lucene Collector and times the execution of: - setScorer() - collect() - doSetNextReader() - needsScores() InternalProfiler facilitates the linking of the Collector graph
-
-
Constructor Summary
Constructors Constructor Description InternalProfileCollector(Collector collector, String reason, List<InternalProfileCollector> children)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CollectorResultgetCollectorTree()LeafCollectorgetLeafCollector(LeafReaderContext context)Create a newcollectorto collect the given context.StringgetName()StringgetReason()longgetTime()ScoreModescoreMode()Indicates what features are required from the scorer.
-
-
-
Constructor Detail
-
InternalProfileCollector
public InternalProfileCollector(Collector collector, String reason, List<InternalProfileCollector> children)
-
-
Method Detail
-
getTime
public long getTime()
- Returns:
- the profiled time for this collector (inclusive of children)
-
getReason
public String getReason()
- Returns:
- a human readable "hint" about what this collector was used for
-
getName
public String getName()
- Returns:
- the lucene class name of the collector
-
getLeafCollector
public LeafCollector getLeafCollector(LeafReaderContext context) throws IOException
Description copied from interface:CollectorCreate a newcollectorto collect the given context.- Specified by:
getLeafCollectorin interfaceCollector- Parameters:
context- next atomic reader context- Throws:
IOException
-
scoreMode
public ScoreMode scoreMode()
Description copied from interface:CollectorIndicates what features are required from the scorer.
-
getCollectorTree
public CollectorResult getCollectorTree()
-
-