Class UpdateTimestampGeneration

    • Constructor Detail

      • UpdateTimestampGeneration

        public UpdateTimestampGeneration()
        Deprecated.
    • Method Detail

      • initialize

        public void initialize​(UpdateTimestamp annotation,
                               Class<?> propertyType)
        Deprecated.
        Description copied from interface: AnnotationValueGeneration
        Initializes this generation strategy for the given annotation instance.
        Specified by:
        initialize in interface AnnotationValueGeneration<UpdateTimestamp>
        Parameters:
        annotation - an instance of the strategy's annotation type. Typically, implementations will retrieve the annotation's attribute values and store them in fields.
        propertyType - the type of the property annotated with the generator annotation.
      • referenceColumnInSql

        public boolean referenceColumnInSql()
        Deprecated.
        Description copied from interface: ValueGeneration
        Determines if the column whose value is generated is included in the column list of the SQL insert or update statement, in the case where the value is generated by the database. For example, this method should return:

        If the value is generated in Java, this method is not called, and so for backward compatibility with Hibernate 5 it is permitted to return any value. On the other hand, when a property value is generated in Java, the column certainly must be included in the column list, and so it's most correct for this method to return true!

        Specified by:
        referenceColumnInSql in interface ValueGeneration
        Returns:
        true if the column is included in the column list of the SQL statement.
      • getDatabaseGeneratedReferencedColumnValue

        public String getDatabaseGeneratedReferencedColumnValue()
        Deprecated.
        Description copied from interface: ValueGeneration
        A SQL expression indicating how to calculate the generated value when the property value is generated in the database and the mapped column is included in the SQL statement. The SQL expression might be:
        • a function call like current_timestamp or nextval('mysequence'), or
        • a syntactic marker like default.

        When the property value is generated in Java, this method is not called, and its value is implicitly the string "?", that is, a JDBC parameter to which the generated value is bound.

        Specified by:
        getDatabaseGeneratedReferencedColumnValue in interface ValueGeneration
        Returns:
        The column value to be used in the generated SQL statement.
      • getDatabaseGeneratedReferencedColumnValue

        public String getDatabaseGeneratedReferencedColumnValue​(Dialect dialect)
        Deprecated.
        Description copied from interface: ValueGeneration
        A SQL expression indicating how to calculate the generated value when the property value is generated in the database and the mapped column is included in the SQL statement. The SQL expression might be:
        • a function call like current_timestamp or nextval('mysequence'), or
        • a syntactic marker like default.

        When the property value is generated in Java, this method is not called, and its value is implicitly the string "?", that is, a JDBC parameter to which the generated value is bound.

        Specified by:
        getDatabaseGeneratedReferencedColumnValue in interface ValueGeneration
        Parameters:
        dialect - The SQL dialect, allowing generation of an expression in dialect-specific SQL.
        Returns:
        The column value to be used in the generated SQL statement.