Record Class Tracker.TrackingEntry
java.lang.Object
java.lang.Record
ch.martinelli.mite4java.domain.Tracker.TrackingEntry
- Enclosing class:
Tracker
public static record Tracker.TrackingEntry(int id, int minutes, OffsetDateTime since)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionTrackingEntry(int id, int minutes, OffsetDateTime since) Creates an instance of aTrackingEntryrecord class. -
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.intid()Returns the value of theidrecord component.intminutes()Returns the value of theminutesrecord component.since()Returns the value of thesincerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
TrackingEntry
Creates an instance of aTrackingEntryrecord class.- Parameters:
id- the value for theidrecord componentminutes- the value for theminutesrecord componentsince- the value for thesincerecord component
-
-
Method Details
-
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. -
id
public int id()Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
minutes
public int minutes()Returns the value of theminutesrecord component.- Returns:
- the value of the
minutesrecord component
-
since
Returns the value of thesincerecord component.- Returns:
- the value of the
sincerecord component
-