T - the temporal type (e.g. Date or Calendar)public abstract class TemporalConverter<T> extends Object implements ValueConverter<T>
EntityClass.| Constructor and Description |
|---|
TemporalConverter(AttributeAccessor attribute,
boolean mapKey)
Creates a new instance of this
TemporalConverter. |
TemporalConverter(javax.persistence.TemporalType type) |
| Modifier and Type | Method and Description |
|---|---|
ColumnExpression |
getExpression(Date value,
GeneratorContext context)
Converts the given value into an SQL expression.
|
ColumnExpression |
getExpression(String defaultValue,
GeneratorContext context)
Use database independent default values.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetExpressionpublic TemporalConverter(AttributeAccessor attribute, boolean mapKey)
TemporalConverter.attribute - the inspected attributemapKey - indicates that the converter is used for the key of a map property@ConstructorProperties(value="type") @Generated(value="lombok") public TemporalConverter(javax.persistence.TemporalType type)
public ColumnExpression getExpression(Date value, GeneratorContext context)
value - the value to convertcontext - the current contextpublic ColumnExpression getExpression(String defaultValue, GeneratorContext context)
getExpression in interface ValueConverter<T>defaultValue - the default value, as given in an DefaultValue expressioncontext - the current context (contains the database dialect).Copyright © 2020 fastnate.org. All rights reserved.