Class LogicalIndexNavigation

java.lang.Object
io.trino.operator.window.pattern.LogicalIndexNavigation

public class LogicalIndexNavigation extends Object
  • Field Details

  • Constructor Details

    • LogicalIndexNavigation

      public LogicalIndexNavigation(Set<Integer> labels, boolean last, boolean running, int logicalOffset, int physicalOffset)
  • Method Details

    • getLabels

      public Set<Integer> getLabels()
    • isLast

      public boolean isLast()
    • getLogicalOffset

      public int getLogicalOffset()
    • getPhysicalOffset

      public int getPhysicalOffset()
    • resolvePosition

      public int resolvePosition(int currentRow, ArrayView matchedLabels, int searchStart, int searchEnd, int patternStart)
      This method is used when evaluating labels during pattern matching, computing row pattern measures, and computing SKIP TO position after finding a match. Search is limited up to the current row in case of running semantics and to the entire match in case of final semantics.
      Returns:
      position within partition, or -1 if matching position was not found
    • withoutLogicalOffset

      public LogicalIndexNavigation withoutLogicalOffset()
    • withLogicalOffset

      public LogicalIndexNavigation withLogicalOffset(int logicalOffset)
    • withoutPhysicalOffset

      public LogicalIndexNavigation withoutPhysicalOffset()
    • withPhysicalOffset

      public LogicalIndexNavigation withPhysicalOffset(int physicalOffset)
    • equals

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

      public int hashCode()
      Overrides:
      hashCode in class Object