Class SQLTable

java.lang.Object
org.datanucleus.store.rdbms.sql.SQLTable

public class SQLTable extends Object
Representation of a table reference in an SQL statement. Has a table, and an alias.
  • Field Details

  • Constructor Details

    • SQLTable

      SQLTable(SQLStatement stmt, Table tbl, DatastoreIdentifier alias, String grpName)
      Constructor for a table involved in an SQLStatement. Package permission so that it can't be created from other packages - i.e to restrict construction to SQLStatement
      Parameters:
      stmt - Statement that this table relates to
      tbl - The underlying table
      alias - Alias to use for this table in the SQLStatement
      grpName - Name of the group this table is in
  • Method Details

    • getSQLStatement

      public SQLStatement getSQLStatement()
    • getTable

      public Table getTable()
    • getAlias

      public DatastoreIdentifier getAlias()
    • getGroupName

      public String getGroupName()
    • hashCode

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

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Stringifier method to return this "table" in a form for use in SQL statements. This can be of the following form(s)
       MYTABLE MYALIAS
       MYTABLE
       
      Overrides:
      toString in class Object
      Returns:
      The String form for use