Record Class STICSFunctions.RollingMean
java.lang.Object
java.lang.Record
net.simplace.sim.components.soil.n2o.STICSFunctions.RollingMean
- Enclosing class:
STICSFunctions
public static record STICSFunctions.RollingMean(double[] lastvalues, int lastindex, double mean)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionRollingMean(double[] lastvalues, int lastindex, double mean) Creates an instance of aRollingMeanrecord 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.intReturns the value of thelastindexrecord component.double[]Returns the value of thelastvaluesrecord component.doublemean()Returns the value of themeanrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
RollingMean
public RollingMean(double[] lastvalues, int lastindex, double mean) Creates an instance of aRollingMeanrecord class.- Parameters:
lastvalues- the value for thelastvaluesrecord componentlastindex- the value for thelastindexrecord componentmean- the value for themeanrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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 '=='. -
lastvalues
public double[] lastvalues()Returns the value of thelastvaluesrecord component.- Returns:
- the value of the
lastvaluesrecord component
-
lastindex
public int lastindex()Returns the value of thelastindexrecord component.- Returns:
- the value of the
lastindexrecord component
-
mean
public double mean()Returns the value of themeanrecord component.- Returns:
- the value of the
meanrecord component
-