Class JoinableClause

  • All Implemented Interfaces:
    ReferenceCountedObject

    public class JoinableClause
    extends Object
    implements ReferenceCountedObject
    Represents everything about a join clause except for the left-hand datasource. In other words, if the full join clause is "t1 JOIN t2 ON t1.x = t2.x" then this class represents "JOIN t2 ON x = t2.x" -- it does not include references to the left-hand "t1".

    Created from PreJoinableClause.

    • Method Detail

      • getJoinable

        public Joinable getJoinable()
        The right-hand Joinable.
      • getJoinType

        public JoinType getJoinType()
        The type of join: LEFT, RIGHT, INNER, or FULL.
      • getCondition

        public JoinConditionAnalysis getCondition()
        The join condition. When referring to right-hand columns, it should include the prefix.
      • includesColumn

        public boolean includesColumn​(String columnName)
        Returns whether "columnName" can be retrieved from the Joinable represented by this clause (i.e., whether it starts with prefix and has at least one other character beyond that).
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • acquireReferences

        public Optional<Closeable> acquireReferences()
        Description copied from interface: ReferenceCountedObject
        This method is expected to increment a reference count and provide a Closeable that decrements the reference count when closed. This is likely just a wrapper around ReferenceCountingCloseableObject.incrementReferenceAndDecrementOnceCloseable(), but may also include any other associated references which should be incremented when this method is called, and decremented/released by the closeable. IMPORTANT NOTE: to fulfill the contract of this method, implementors must return a closeable to indicate that the reference can be acquired, even if there is nothing to close. Implementors should avoid allowing this method or the Closeable it creates to throw exceptions. For callers: if this method returns non-empty, IT MUST BE CLOSED, else reference counts can potentially leak.
        Specified by:
        acquireReferences in interface ReferenceCountedObject