Package com.azure.android.core.util
Class UnixTime
- java.lang.Object
-
- com.azure.android.core.util.UnixTime
-
public final class UnixTime extends java.lang.ObjectA wrapper over org.threeten.bp.OffsetDateTime used for specifying unix seconds format during serialization and deserialization.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)org.threeten.bp.OffsetDateTimegetDateTime()Get the underlying DateTime.inthashCode()java.lang.StringtoString()
-
-
-
Constructor Detail
-
UnixTime
public UnixTime(org.threeten.bp.OffsetDateTime dateTime)
Creates aUnixTime object with the specified DateTime.- Parameters:
dateTime- The DateTime object to wrap
-
UnixTime
public UnixTime(long unixSeconds)
Creates a UnixTime object with the specified DateTime.- Parameters:
unixSeconds- The Unix seconds value
-
-
Method Detail
-
getDateTime
public org.threeten.bp.OffsetDateTime getDateTime()
Get the underlying DateTime.- Returns:
- The underlying DateTime
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
-