Record Class Timed<T>
java.lang.Object
java.lang.Record
io.reactivex.rxjava4.schedulers.Timed<T>
- Type Parameters:
T- the value type- Record Components:
value- the item to storetime- the time valueunit- the unit of time
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.longtime()Returns the value of thetimerecord component.longReturns the contained time value in the time unit specified.toString()Returns a string representation of this record class.unit()Returns the value of theunitrecord component.value()Returns the value of thevaluerecord component.
-
Constructor Details
-
Timed
Constructs aTimedinstance with the given value and time information.- Parameters:
value- the value to holdtime- the time to holdunit- the time unit, not null- Throws:
NullPointerException- ifvalueorunitisnull
-
-
Method Details
-
time
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
value
-
time
-
unit
-