Record Class RehashDecision.Required
java.lang.Object
java.lang.Record
com.svenruppert.jsentinel.credential.password.RehashDecision.Required
- Record Components:
reason- dominant reason for the rehash; deterministic so multiple verifications of the same envelope under the same policy yield the same reasontargetPolicyVersion- policy version the rehash should target; usually the active policy version
- All Implemented Interfaces:
RehashDecision
- Enclosing interface:
RehashDecision
public static record RehashDecision.Required(RehashReason reason, int targetPolicyVersion)
extends Record
implements RehashDecision
-
Nested Class Summary
Nested classes/interfaces inherited from interface RehashDecision
RehashDecision.NotRequired, RehashDecision.RequiredModifier and TypeInterfaceDescriptionstatic final recordstatic final record -
Constructor Summary
ConstructorsConstructorDescriptionRequired(RehashReason reason, int targetPolicyVersion) Creates an instance of aRequiredrecord 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.reason()Returns the value of thereasonrecord component.intReturns the value of thetargetPolicyVersionrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Required
Creates an instance of aRequiredrecord class.- Parameters:
reason- the value for thereasonrecord componenttargetPolicyVersion- the value for thetargetPolicyVersionrecord 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. -
reason
-
targetPolicyVersion
public int targetPolicyVersion()Returns the value of thetargetPolicyVersionrecord component.- Returns:
- the value of the
targetPolicyVersionrecord component
-