@Documented @Retention(value=RUNTIME) @Target(value=METHOD) @AdapterDefinition(storageTypePreferences={long.class,java.lang.Long.class,java.lang.String.class}) public @interface DateTimeAdapter
DateTime
,
DateMidnight
, LocalDateTime
, LocalDate
and also
Date
. Explicit use allows a different time zone to be
used, but this only works for Joda-Time objects.
Example:
public interface UserInfo extends Storable { @DateTimeAdapter(timeZone="UTC") DateTime getModifyDateTime(); void setModifyDateTime(DateTime dt); ... }
AdapterDefinition
Modifier and Type | Optional Element and Description |
---|---|
java.lang.String |
timeZone
Optionally specify a time zone to apply to new DateTimes, overriding the
default time zone.
|
Copyright © 2006-2013 Amazon Technologies, Inc.. All Rights Reserved.