Client and backend. This class is shared: the same code is compiled into your app and into your server, so everything on this page works in both.
public interface ChronoZonedDateTime<D extends ChronoLocalDate>
ExtendsComparable<ChronoZonedDateTime<?>>, Temporal, TemporalAccessor
Known subtypesZonedDateTime
A date and a time of day in a time zone.
Methods
public abstract ChronoLocalDateTime<D> toLocalDateTime() | The date and time on the wall clock. |
public abstract ZoneOffset getOffset() | The offset from UTC. |
public abstract ZoneId getZone() | The zone. |
public default D toLocalDate() | The date. |
public default LocalTime toLocalTime() | The time of day. |
public default long toEpochSecond() | The seconds since 1970-01-01T00:00Z. |
public default Instant toInstant() | The moment this is. |
public default boolean isAfter(ChronoZonedDateTime<?> other) | Whether this moment comes after other. |
public default boolean isBefore(ChronoZonedDateTime<?> other) | Whether this moment comes before other. |
public default boolean isEqual(ChronoZonedDateTime<?> other) | Whether this is the same moment as other. |
Inherited methods
From Comparable
Method details
toLocalDateTime
public abstract ChronoLocalDateTime<D> toLocalDateTime()The date and time on the wall clock.
getOffset
public abstract ZoneOffset getOffset()The offset from UTC.
getZone
public abstract ZoneId getZone()The zone.
toLocalDate
public default D toLocalDate()The date.
toLocalTime
public default LocalTime toLocalTime()The time of day.
toEpochSecond
public default long toEpochSecond()The seconds since 1970-01-01T00:00Z.
toInstant
public default Instant toInstant()The moment this is.
isAfter
public default boolean isAfter(ChronoZonedDateTime<?> other)Whether this moment comes after
other.isBefore
public default boolean isBefore(ChronoZonedDateTime<?> other)Whether this moment comes before
other.isEqual
public default boolean isEqual(ChronoZonedDateTime<?> other)Whether this is the same moment as
other.