Class SQLJoinStatement

java.lang.Object
no.sikt.graphitron.definitions.sql.SQLJoin
no.sikt.graphitron.definitions.sql.SQLJoinStatement

public class SQLJoinStatement extends SQLJoin
An extension of SQLJoin with additional data on which table to join towards and which alias should be used. This class then contains all the information necessary to construct a complete join statement.
  • Constructor Details

    • SQLJoinStatement

      public SQLJoinStatement(JoinListSequence joinSequence, JoinElement joinTargetTable, Alias joinAlias, List<SQLJoinField> joinFields, boolean nullable)
      Parameters:
      joinTargetTable - The "right" side of a join statement. This is the table to be joined with.
      joinFields - List of any conditions for the join operation.
      nullable - What kind of join operation is to be used.
  • Method Details

    • getJoinSequence

      public JoinListSequence getJoinSequence()
      Overrides:
      getJoinSequence in class SQLJoin
      Returns:
      Source table to join from. The "left" side of a join statement.
    • getJoinTargetTable

      public JoinElement getJoinTargetTable()
      Returns:
      The target table to be joined with. The "right" side of a join statement.
    • getJoinAlias

      public Alias getJoinAlias()
      Returns:
      The alias to be used to uniquely distinguish this join operation.
    • toJoinString

      public CodeBlock toJoinString()
      Returns:
      A string that contains a complete join statement followed by all conditions set for this join.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object