Class RelDistributions.RelDistributionImpl

    • Field Detail

      • ORDERING

        private static final com.google.common.collect.Ordering<java.lang.Iterable<java.lang.Integer>> ORDERING
    • Method Detail

      • toString

        public java.lang.String toString()
        Description copied from interface: RelTrait
        Returns a succinct name for this trait. The planner may use this String to describe the trait.
        Specified by:
        toString in interface RelTrait
        Overrides:
        toString in class java.lang.Object
      • getKeys

        @Nonnull
        public java.util.List<java.lang.Integer> getKeys()
        Description copied from interface: RelDistribution
        Returns the ordinals of the key columns.

        Order is important for some types (RANGE); other types (HASH) consider it unimportant but impose an arbitrary order; other types (BROADCAST, SINGLETON) never have keys.

        Specified by:
        getKeys in interface RelDistribution
      • getTraitDef

        public RelDistributionTraitDef getTraitDef()
        Description copied from interface: RelTrait
        Returns the RelTraitDef that defines this RelTrait.
        Specified by:
        getTraitDef in interface RelTrait
        Returns:
        the RelTraitDef that defines this RelTrait
      • satisfies

        public boolean satisfies​(RelTrait trait)
        Description copied from interface: RelTrait
        Returns whether this trait satisfies a given trait.

        A trait satisfies another if it is the same or stricter. For example, ORDER BY x, y satisfies ORDER BY x.

        A trait's satisfies relation must be a partial order (reflexive, anti-symmetric, transitive). Many traits cannot be "loosened"; their satisfies is an equivalence relation, where only X satisfies X.

        If a trait has multiple values (see RelCompositeTrait) a collection (T0, T1, ...) satisfies T if any Ti satisfies T.

        Specified by:
        satisfies in interface RelTrait
        Parameters:
        trait - Given trait
        Returns:
        Whether this trait subsumes a given trait
      • register

        public void register​(RelOptPlanner planner)
        Description copied from interface: RelTrait
        Registers a trait instance with the planner.

        This is an opportunity to add rules that relate to that trait. However, typical implementations will do nothing.

        Specified by:
        register in interface RelTrait
        Parameters:
        planner - Planner
      • isTop

        public boolean isTop()
        Description copied from interface: RelMultipleTrait
        Returns whether this trait is satisfied by every instance of the trait (including itself).
        Specified by:
        isTop in interface RelMultipleTrait