DateInterval | API reference | Android Developers (original) (raw)
class DateInterval : Serializable
This class represents date interval. It is a pair of long representing from date 1 to date 2.
Summary
Public constructors |
---|
DateInterval(from: Long, to: Long) Constructor given from date and to date. |
Public methods | |
---|---|
Boolean | equals(other: Any?) Override equals |
Long | getFromDate() Get the from date. |
Long | getToDate() Get the to date. |
Int | hashCode() Override hashcode |
String | toString() Override toString |
Public constructors
DateInterval
DateInterval(
from: Long,
to: Long)
Constructor given from date and to date.
Parameters | |
---|---|
from | Long: The from date in date interval. |
to | Long: The to date in date interval. |
Public methods
equals
fun equals(other: Any?): Boolean
Override equals
Parameters | |
---|---|
obj | the reference object with which to compare. |
Return | |
---|---|
Boolean | true if this object is the same as the obj argument; false otherwise. |
getFromDate
fun getFromDate(): Long
Get the from date.
Return | |
---|---|
Long | the from date in dateInterval. |
getToDate
fun getToDate(): Long
Get the to date.
Return | |
---|---|
Long | the to date in dateInterval. |
hashCode
fun hashCode(): Int
Override hashcode
Return | |
---|---|
Int | a hash code value for this object. |
toString
fun toString(): String
Override toString
Return | |
---|---|
String | a string representation of the object. |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.