Class RhsRewriteCandidate

java.lang.Object
org.apache.druid.segment.join.filter.rewrite.RhsRewriteCandidate

public class RhsRewriteCandidate extends Object
A candidate is an RHS column that appears in a filter, along with the value being filtered on, plus the joinable clause associated with the table that the RHS column is from.
  • Constructor Details

    • RhsRewriteCandidate

      public RhsRewriteCandidate(@Nonnull JoinableClause joinableClause, String rhsColumn, @Nullable String valueForRewrite, boolean isDirectRewrite)
  • Method Details

    • getJoinableClause

      @Nonnull public JoinableClause getJoinableClause()
    • getRhsColumn

      public String getRhsColumn()
    • getValueForRewrite

      @Nullable public String getValueForRewrite()
    • isDirectRewrite

      public boolean isDirectRewrite()
      A direct rewrite occurs when we filter on an RHS column that is also part of a join equicondition. For example, if we have the filter (j.x = 'hello') and the join condition is (y = j.x), we can directly rewrite the j.x filter to (y = 'hello').
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object