Class DeployTableJoin

java.lang.Object
io.ebeaninternal.server.deploy.meta.DeployTableJoin

public final class DeployTableJoin extends Object
Represents a join to another table during deployment phase.

This gets converted into a immutable TableJoin when complete.

  • Constructor Details

    • DeployTableJoin

      public DeployTableJoin()
      Create a DeployTableJoin.
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • hasJoinColumns

      public boolean hasJoinColumns()
      Return true if the JoinOnPair have been set.
    • setColumns

      public void setColumns(DeployTableJoinColumn[] cols, boolean reverse)
      Copy all the columns to this join potentially reversing the columns.
    • addJoinColumn

      public void addJoinColumn(DeployTableJoinColumn pair)
      Add a join pair
    • addJoinColumn

      public void addJoinColumn(io.ebeaninternal.server.deploy.parse.DeployUtil deploy, boolean order, jakarta.persistence.JoinColumn jc, BeanTable beanTable)
      Add a JoinColumn

      The order is generally true for OneToMany and false for ManyToOne relationships.

    • addJoinColumn

      public void addJoinColumn(io.ebeaninternal.server.deploy.parse.DeployUtil util, boolean order, jakarta.persistence.JoinColumn[] jcArray, BeanTable beanTable)
      Add a JoinColumn array.
    • addJoinColumn

      public void addJoinColumn(io.ebeaninternal.server.deploy.parse.DeployUtil util, boolean order, Set<jakarta.persistence.JoinColumn> joinColumns, BeanTable beanTable)
      Add a JoinColumn set.
    • columns

      public DeployTableJoinColumn[] columns()
      Return the join columns.
    • getTable

      public String getTable()
      Return the joined table name.
    • setTable

      public void setTable(String table)
      set the joined table name.
    • getType

      public SqlJoinType getType()
      Return the type of join. LEFT OUTER JOIN etc.
    • setType

      public void setType(SqlJoinType type)
    • getExtraWhere

      public String getExtraWhere()
      Returns the clause of an extra @Where annotation.
    • setExtraWhere

      public void setExtraWhere(String extraWhere)
    • createInverse

      public DeployTableJoin createInverse(String tableName)
    • copyTo

      public void copyTo(DeployTableJoin destJoin, boolean reverse, String tableName)
    • copyWithoutType

      public void copyWithoutType(DeployTableJoin destJoin, boolean reverse, String tableName)
    • clear

      public void clear()
      Clear the join columns due to an implied mappedBy.

      Effectively prior to clear this was considered a unidirectional OneToMany and the foreign key was defined by naming convention. Clearing this means that it uses the foreign key as defined by the implied mappedBy property (the only ManyToOne that maps back to the parent (that holds the OneToMany).