Interface SelectStatementGenerator

All Known Implementing Classes:
AbstractSelectStatementGenerator, DiscriminatorStatementGenerator, UnionStatementGenerator

public interface SelectStatementGenerator
Generator of SQL SELECT Statements.
  • Field Details

    • OPTION_ALLOW_NULLS

      static final String OPTION_ALLOW_NULLS
      Option to allow null values as elements of an array or collection.
      See Also:
    • OPTION_SELECT_DN_TYPE

      static final String OPTION_SELECT_DN_TYPE
      Option to add "DN_TYPE" to the SELECT clause as kind of discriminator.
      See Also:
    • OPTION_RESTRICT_DISCRIM

      static final String OPTION_RESTRICT_DISCRIM
      Option to add a WHERE clause to restrict to the discriminator value.
      See Also:
    • OPTION_DONT_RESTRICT_DISCRIM

      static final String OPTION_DONT_RESTRICT_DISCRIM
      Option to not add a WHERE clause to restrict to the discriminator value.
      See Also:
    • OPTION_INCLUDE_SOFT_DELETES

      static final String OPTION_INCLUDE_SOFT_DELETES
      Option to omit a WHERE clause restricting to non-soft-deleted objects (only relevant if the candidate has soft-delete enabled.
      See Also:
  • Method Details

    • getStatement

      SelectStatement getStatement(org.datanucleus.ExecutionContext ec)
      Accessor for the statement.
      Parameters:
      ec - ExecutionContext
      Returns:
      The SQLStatement
    • setParentStatement

      void setParentStatement(SQLStatement stmt)
      Method to set the parent statement. Must be set before calling getStatement().
      Parameters:
      stmt - The parent statement
    • setOption

      Method to set a property.
      Parameters:
      name - Name of the property
      Returns:
      This generator
    • unsetOption

      SelectStatementGenerator unsetOption(String name)
      Method to unset a property.
      Parameters:
      name - Name of the property
      Returns:
      This generator
    • hasOption

      boolean hasOption(String name)
      Whether the generator has a particular option set.
      Parameters:
      name - Name of the option
      Returns:
      Whether it is set