Record Class AffinityEngine.ContenderPolicy
java.lang.Object
java.lang.Record
ke.ric.api.affinity.AffinityEngine.ContenderPolicy
- Enclosing class:
AffinityEngine<K>
public static record AffinityEngine.ContenderPolicy(double clearMargin, double contenderWindow, int maxContenders)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionContenderPolicy(double clearMargin, double contenderWindow, int maxContenders) Creates an instance of aContenderPolicyrecord class. -
Method Summary
Modifier and TypeMethodDescriptiondoubleReturns the value of theclearMarginrecord component.doubleReturns the value of thecontenderWindowrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intReturns the value of themaxContendersrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ContenderPolicy
public ContenderPolicy(double clearMargin, double contenderWindow, int maxContenders) Creates an instance of aContenderPolicyrecord class.- Parameters:
clearMargin- the value for theclearMarginrecord componentcontenderWindow- the value for thecontenderWindowrecord componentmaxContenders- the value for themaxContendersrecord 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. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
clearMargin
public double clearMargin()Returns the value of theclearMarginrecord component.- Returns:
- the value of the
clearMarginrecord component
-
contenderWindow
public double contenderWindow()Returns the value of thecontenderWindowrecord component.- Returns:
- the value of the
contenderWindowrecord component
-
maxContenders
public int maxContenders()Returns the value of themaxContendersrecord component.- Returns:
- the value of the
maxContendersrecord component
-