| Modifier and Type | Field and Description |
|---|---|
| public static final Date | PROLEPTIC_GREGORIAN_CHANGE
Gregorian change date for a |
| public static final TimeZone | UTC
UTC time zone. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static long | Returns: the date valuethe milliseconds ms)Convert a local datetime in millis to an encoded date. |
| public static ValueDate | Returns: the valuethe cast information provider provider, TimeZone time zone, or timeZone, Date null for defaultthe date date)Get or create a date value for the given date. |
| public static ValueTime | Returns: the valuethe cast information provider provider, TimeZone time zone, or timeZone, Time null for defaultthe time time)Get or create a time value for the given time. |
| public static ValueTimestamp | Returns: the valuethe cast information provider provider, TimeZone time zone, or timeZone, Timestamp null for defaultthe timestamp timestamp)Get or create a timestamp value for the given timestamp. |
| public static ValueTimestamp | Returns: the valuethe cast information provider provider, long the milliseconds ms, int the nanoseconds nanos)Get or create a timestamp value for the given date/time in millis. |
| public static long | Returns: the number of milliseconds (UTC)the cast information provider provider, TimeZone the timezone of the parameters, or null for the default
timezone tz, long date value dateValue, long nanoseconds since midnight timeNanos)Calculate the milliseconds since 1970-01-01 (UTC) for the given date and time (in the specified timezone). |
| public static int | Returns: local time zone offsetthe cast information provider provider, long milliseconds since Epoch in UTC ms)Returns local time zone offset for a specified timestamp. |
| public static TypeInfo | Returns: the value type, ornull if not supportedthe Java class clazz)Get the type information for the given legacy Java class. |
| public static Value | Returns: the value, ornull if not supportedthe session session, Object the value x)Convert a legacy Java object to a value. |
| public static long | Returns: the nanosecondsthe milliseconds ms)Convert a time in milliseconds in local time to the nanoseconds since midnight. |
| private static ValueTimestamp | |
| public static Date | Returns: the datethe cast information provider provider, TimeZone the target time zone timeZone, Value the value to convert value)Get the date value converted to the specified time zone. |
| public static Time | Returns: the timethe cast information provider provider, TimeZone the target time zone timeZone, Value the value to convert value)Get the time value converted to the specified time zone. |
| public static Timestamp | Returns: the timestampthe cast information provider provider, TimeZone the target time zone timeZone, Value the value to convert value)Get the timestamp value converted to the specified time zone. |
| public static < the type T> T | Returns: an instance of the specified class, ornull if not supportedthe class type, Value the value value, CastDataProvider the cast information provider provider)Converts the specified value to an object of the specified legacy type. |
| PROLEPTIC_GREGORIAN_CHANGE | back to summary |
|---|---|
| public static final Date PROLEPTIC_GREGORIAN_CHANGE Gregorian change date for a | |
| UTC | back to summary |
|---|---|
| public static final TimeZone UTC UTC time zone. | |
| LegacyDateTimeUtils | back to summary |
|---|---|
| private LegacyDateTimeUtils() | |
| dateValueFromLocalMillis | back to summary |
|---|---|
| public static long dateValueFromLocalMillis(long ms) Convert a local datetime in millis to an encoded date.
| |
| fromDate | back to summary |
|---|---|
| public static ValueDate fromDate(CastDataProvider provider, TimeZone timeZone, Date date) Get or create a date value for the given date.
| |
| fromTime | back to summary |
|---|---|
| public static ValueTime fromTime(CastDataProvider provider, TimeZone timeZone, Time time) Get or create a time value for the given time.
| |
| fromTimestamp | back to summary |
|---|---|
| public static ValueTimestamp fromTimestamp(CastDataProvider provider, TimeZone timeZone, Timestamp timestamp) Get or create a timestamp value for the given timestamp.
| |
| fromTimestamp | back to summary |
|---|---|
| public static ValueTimestamp fromTimestamp(CastDataProvider provider, long ms, int nanos) Get or create a timestamp value for the given date/time in millis.
| |
| getMillis | back to summary |
|---|---|
| public static long getMillis(CastDataProvider provider, TimeZone tz, long dateValue, long timeNanos) Calculate the milliseconds since 1970-01-01 (UTC) for the given date and time (in the specified timezone).
| |
| getTimeZoneOffsetMillis | back to summary |
|---|---|
| public static int getTimeZoneOffsetMillis(CastDataProvider provider, long ms) Returns local time zone offset for a specified timestamp.
| |
| legacyClassToType | back to summary |
|---|---|
| public static TypeInfo legacyClassToType(Class<?> clazz) Get the type information for the given legacy Java class. | |
| legacyObjectToValue | back to summary |
|---|---|
| public static Value legacyObjectToValue(CastDataProvider session, Object x) Convert a legacy Java object to a value.
| |
| nanosFromLocalMillis | back to summary |
|---|---|
| public static long nanosFromLocalMillis(long ms) Convert a time in milliseconds in local time to the nanoseconds since midnight.
| |
| timestampFromLocalMillis | back to summary |
|---|---|
| private static ValueTimestamp timestampFromLocalMillis(long ms, int nanos) | |
| toDate | back to summary |
|---|---|
| public static Date toDate(CastDataProvider provider, TimeZone timeZone, Value value) Get the date value converted to the specified time zone.
| |
| toTime | back to summary |
|---|---|
| public static Time toTime(CastDataProvider provider, TimeZone timeZone, Value value) Get the time value converted to the specified time zone.
| |
| toTimestamp | back to summary |
|---|---|
| public static Timestamp toTimestamp(CastDataProvider provider, TimeZone timeZone, Value value) Get the timestamp value converted to the specified time zone.
| |
| valueToLegacyType | back to summary |
|---|---|
| public static <T> T valueToLegacyType(Class<T> type, Value value, CastDataProvider provider) Converts the specified value to an object of the specified legacy type.
| |