public interface JoinMatcher
Joinable.makeJoinMatcher(org.apache.druid.segment.ColumnSelectorFactory, org.apache.druid.segment.join.JoinConditionAnalysis, boolean) and used by HashJoinEngine to implement a join.
A typical usage would go something like:
matcher.matchCondition();
while (matcher.hasMatch()) {
// Do something with the match
matcher.nextMatch();
}
| Modifier and Type | Method and Description |
|---|---|
ColumnSelectorFactory |
getColumnSelectorFactory()
Returns a factory for reading columns from the
Joinable that correspond to matched rows. |
boolean |
hasMatch()
Returns whether the active matcher (
matchCondition() or matchRemainder()) has matched something. |
void |
matchCondition()
|
boolean |
matchingRemainder()
Returns whether this matcher is currently matching the remainder (i.e.
|
void |
matchRemainder()
Matches every row that has not already been matched.
|
void |
nextMatch()
Moves on to the next match.
|
void |
reset()
Clears any active matches.
|
ColumnSelectorFactory getColumnSelectorFactory()
Joinable that correspond to matched rows.void matchCondition()
ColumnSelectorFactory and JoinConditionAnalysis supplied to
Joinable.makeJoinMatcher(org.apache.druid.segment.ColumnSelectorFactory, org.apache.druid.segment.join.JoinConditionAnalysis, boolean).
After calling this method, hasMatch() will return whether at least one row matched. After reading that
row, nextMatch() can be used to move on to the next row.void matchRemainder()
hasMatch() will return whether at least one row matched. After reading that
row, nextMatch() can be used to move on to the next row.
Will only work correctly if Joinable.makeJoinMatcher(org.apache.druid.segment.ColumnSelectorFactory, org.apache.druid.segment.join.JoinConditionAnalysis, boolean) was called with remainderNeeded == true.boolean hasMatch()
matchCondition() or matchRemainder()) has matched something.void nextMatch()
hasMatch() is true.boolean matchingRemainder()
matchRemainder() was the
most recent match method called).void reset()
Copyright © 2011–2020 The Apache Software Foundation. All rights reserved.