Class Format

  • All Implemented Interfaces:
    HasSQL, Typed

    public final class Format
    extends Operation1
    A format clause such as FORMAT JSON.
    • Method Detail

      • getValue

        public Value getValue​(SessionLocal session)
        Description copied from class: Expression
        Return the resulting value for the current row.
        Specified by:
        getValue in class Expression
        Parameters:
        session - the session
        Returns:
        the result
      • getValue

        public Value getValue​(Value value)
        Returns the value with applied format.
        Parameters:
        value - the value
        Returns:
        the value with applied format
      • optimize

        public Expression optimize​(SessionLocal session)
        Description copied from class: Expression
        Try to optimize the expression.
        Specified by:
        optimize in class Expression
        Parameters:
        session - the session
        Returns:
        the optimized expression
      • isIdentity

        public boolean isIdentity()
        Description copied from class: Expression
        Check if this is an identity column.
        Overrides:
        isIdentity in class Expression
        Returns:
        true if it is an identity column
      • getUnenclosedSQL

        public java.lang.StringBuilder getUnenclosedSQL​(java.lang.StringBuilder builder,
                                                        int sqlFlags)
        Description copied from class: Expression
        Get the SQL statement of this expression. This may not always be the original SQL statement, especially after optimization. Enclosing '(' and ')' are never appended.
        Specified by:
        getUnenclosedSQL in class Expression
        Parameters:
        builder - string builder
        sqlFlags - formatting flags
        Returns:
        the specified string builder
      • getNullable

        public int getNullable()
        Description copied from class: Expression
        Check whether this expression is a column and can store NULL.
        Overrides:
        getNullable in class Expression
        Returns:
        whether NULL is allowed
      • getTableName

        public java.lang.String getTableName()
        Description copied from class: Expression
        Get the table name, or null
        Overrides:
        getTableName in class Expression
        Returns:
        the table name
      • getColumnName

        public java.lang.String getColumnName​(SessionLocal session,
                                              int columnIndex)
        Description copied from class: Expression
        Get the column name or alias name of this expression.
        Overrides:
        getColumnName in class Expression
        Parameters:
        session - the session
        columnIndex - 0-based column index
        Returns:
        the column name