Record Class SeasonStateImpl<S extends ThermooSeason>
java.lang.Object
java.lang.Record
com.github.thedeathlycow.thermoo.impl.season.SeasonStateImpl<S>
- All Implemented Interfaces:
ThermooSeasonState<S>
public record SeasonStateImpl<S extends ThermooSeason>(S extends ThermooSeason season, float progress)
extends Record
implements ThermooSeasonState<S>
-
Constructor Summary
ConstructorsConstructorDescriptionSeasonStateImpl(S season, float progress) Creates an instance of aSeasonStateImplrecord 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.floatprogress()Returns the value of theprogressrecord component.season()Returns the value of theseasonrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SeasonStateImpl
Creates an instance of aSeasonStateImplrecord class.- Parameters:
season- the value for theseasonrecord componentprogress- the value for theprogressrecord 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. -
season
Returns the value of theseasonrecord component.- Specified by:
seasonin interfaceThermooSeasonState<S extends ThermooSeason>- Returns:
- the value of the
seasonrecord component
-
progress
public float progress()Returns the value of theprogressrecord component.- Specified by:
progressin interfaceThermooSeasonState<S extends ThermooSeason>- Returns:
- the value of the
progressrecord component
-