Interface SqlAstTranslator<T extends JdbcOperation>

All Superinterfaces:
SqlAstWalker
All Known Implementing Classes:
AbstractSqlAstTranslator, CockroachSqlAstTranslator, DB2iSqlAstTranslator, DB2SqlAstTranslator, DB2zSqlAstTranslator, H2SqlAstTranslator, HANASqlAstTranslator, HSQLSqlAstTranslator, MariaDBSqlAstTranslator, MySQLSqlAstTranslator, OracleSqlAstTranslator, PostgreSQLSqlAstTranslator, SpannerSqlAstTranslator, SqlAstTranslatorWithMerge, SqlAstTranslatorWithUpsert, SQLServerSqlAstTranslator, StandardSqlAstTranslator, SybaseASESqlAstTranslator, SybaseSqlAstTranslator, TiDBSqlAstTranslator

public interface SqlAstTranslator<T extends JdbcOperation> extends SqlAstWalker
  • Method Details

    • getSessionFactory

      SessionFactoryImplementor getSessionFactory()
    • getLiteralValue

      <X> X getLiteralValue(Expression expression)
      Returns the literal value of the given expression, inlining a parameter value if necessary.
      Since:
      7.0
    • renderNamedSetReturningFunction

      @Incubating void renderNamedSetReturningFunction(String functionName, List<? extends SqlAstNode> sqlAstArguments, AnonymousTupleTableGroupProducer tupleType, String tableIdentifierVariable, SqlAstNodeRenderingMode argumentRenderingMode)
      Renders a named set returning function.
      Since:
      7.0
    • render

      void render(SqlAstNode sqlAstNode, SqlAstNodeRenderingMode renderingMode)
      Renders the given SQL AST node with the given rendering mode.
    • supportsFilterClause

      boolean supportsFilterClause()
      Whether the FILTER clause for aggregate functions is supported.
    • getCurrentQueryPart

      QueryPart getCurrentQueryPart()
      Returns the current query part that is translated.
    • getCurrentClauseStack

      Stack<Clause> getCurrentClauseStack()
    • getAffectedTableNames

      Set<String> getAffectedTableNames()
      Not the best spot for this. Returns the table names collected while walking the SQL AST. It's ok here because the translator is consider a one-time-use. It just needs to be called after translation. A better option is probably to have "translation" objects that expose the affected table-names.
    • translate

      T translate(JdbcParameterBindings jdbcParameterBindings, QueryOptions queryOptions)