Record Class InjuryPredictor.TrainingLoad
java.lang.Object
java.lang.Record
org.episteme.social.sports.InjuryPredictor.TrainingLoad
- All Implemented Interfaces:
Serializable
- Enclosing class:
InjuryPredictor
public static record InjuryPredictor.TrainingLoad(double duration, double intensity, double frequency, String type)
extends Record
implements Serializable
Detailed data regarding an individual training session.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionTrainingLoad(double duration, double intensity, double frequency, String type) Creates an instance of aTrainingLoadrecord class. -
Method Summary
Modifier and TypeMethodDescriptiondoubleduration()Returns the value of thedurationrecord component.final booleanIndicates whether some other object is "equal to" this one.doubleReturns the value of thefrequencyrecord component.final inthashCode()Returns a hash code value for this object.doubleReturns the value of theintensityrecord component.final StringtoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.
-
Constructor Details
-
TrainingLoad
Creates an instance of aTrainingLoadrecord class.- Parameters:
duration- the value for thedurationrecord componentintensity- the value for theintensityrecord componentfrequency- the value for thefrequencyrecord componenttype- the value for thetyperecord 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. -
duration
public double duration()Returns the value of thedurationrecord component.- Returns:
- the value of the
durationrecord component
-
intensity
public double intensity()Returns the value of theintensityrecord component.- Returns:
- the value of the
intensityrecord component
-
frequency
public double frequency()Returns the value of thefrequencyrecord component.- Returns:
- the value of the
frequencyrecord component
-
type
Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-