Record Class ValidationUtils.RequiredRole
java.lang.Object
java.lang.Record
io.fluxzero.sdk.tracking.handling.validation.ValidationUtils.RequiredRole
- Enclosing class:
ValidationUtils
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedRequiredRole(String value, boolean throwIfUnauthorized, boolean requiresUser, boolean forbidsUser) Creates an instance of aRequiredRolerecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.booleanReturns the value of theforbidsUserrecord component.final inthashCode()Returns a hash code value for this object.booleanReturns the value of therequiresUserrecord component.booleanReturns the value of thethrowIfUnauthorizedrecord component.final StringtoString()Returns a string representation of this record class.value()Returns the value of thevaluerecord component.
-
Constructor Details
-
RequiredRole
protected RequiredRole(@Nullable String value, boolean throwIfUnauthorized, boolean requiresUser, boolean forbidsUser) Creates an instance of aRequiredRolerecord class.- Parameters:
value- the value for thevaluerecord componentthrowIfUnauthorized- the value for thethrowIfUnauthorizedrecord componentrequiresUser- the value for therequiresUserrecord componentforbidsUser- the value for theforbidsUserrecord 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. -
value
Returns the value of thevaluerecord component.- Returns:
- the value of the
valuerecord component
-
throwIfUnauthorized
public boolean throwIfUnauthorized()Returns the value of thethrowIfUnauthorizedrecord component.- Returns:
- the value of the
throwIfUnauthorizedrecord component
-
requiresUser
public boolean requiresUser()Returns the value of therequiresUserrecord component.- Returns:
- the value of the
requiresUserrecord component
-
forbidsUser
public boolean forbidsUser()Returns the value of theforbidsUserrecord component.- Returns:
- the value of the
forbidsUserrecord component
-