Interface PositionBasedContext<T extends PositionBasedContext<?>>

Type Parameters:
T - concrete position-based context type
All Superinterfaces:
ContainerContext
All Known Implementing Classes:
IntervalContext

public interface PositionBasedContext<T extends PositionBasedContext<?>> extends ContainerContext
Interface for all position-based contexts. Immutable by default.
  • Method Details

    • intersects

      Tristate intersects(T other)
      Check whether this and other intersects
      Parameters:
      other - value-based context
      Returns:
      true on perfect match, maybe on part match and otherwise false
    • lessThanEqual

      Tristate lessThanEqual(T other)
      Check whether this is less or equal to other
      Parameters:
      other - value-based context
      Returns:
      true on perfect match, maybe on part match and otherwise false
    • exactShift

      T exactShift(T n)
      Shifts the position(s) by n
      Parameters:
      n - number of shifts
      Returns:
      new position-based context
    • union

      T union(T other)
      Unions this with other
      Parameters:
      other - other position-based context
      Returns:
      new position-based context