Record Class SecurityOperationResult
java.lang.Object
java.lang.Record
com.loomcache.server.security.SecurityOperationResult
public record SecurityOperationResult(boolean completed, boolean denied, @Nullable MessageType responseType, byte status, @Nullable String failure)
extends Record
Result metadata observed by
SecurityInterceptor.after(SecurityOperationContext, SecurityOperationResult).-
Constructor Summary
ConstructorsConstructorDescriptionSecurityOperationResult(boolean completed, boolean denied, @Nullable MessageType responseType, byte status, @Nullable String failure) Creates an instance of aSecurityOperationResultrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of thecompletedrecord component.static SecurityOperationResultbooleandenied()Returns the value of thedeniedrecord component.static SecurityOperationResultfinal booleanIndicates whether some other object is "equal to" this one.static SecurityOperationResultfailed(RuntimeException failure) @Nullable Stringfailure()Returns the value of thefailurerecord component.final inthashCode()Returns a hash code value for this object.@Nullable MessageTypeReturns the value of theresponseTyperecord component.bytestatus()Returns the value of thestatusrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SecurityOperationResult
public SecurityOperationResult(boolean completed, boolean denied, @Nullable MessageType responseType, byte status, @Nullable String failure) Creates an instance of aSecurityOperationResultrecord class.- Parameters:
completed- the value for thecompletedrecord componentdenied- the value for thedeniedrecord componentresponseType- the value for theresponseTyperecord componentstatus- the value for thestatusrecord componentfailure- the value for thefailurerecord component
-
-
Method Details
-
completed
-
denied
-
failed
-
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. -
completed
public boolean completed()Returns the value of thecompletedrecord component.- Returns:
- the value of the
completedrecord component
-
denied
public boolean denied()Returns the value of thedeniedrecord component.- Returns:
- the value of the
deniedrecord component
-
responseType
Returns the value of theresponseTyperecord component.- Returns:
- the value of the
responseTyperecord component
-
status
public byte status()Returns the value of thestatusrecord component.- Returns:
- the value of the
statusrecord component
-
failure
Returns the value of thefailurerecord component.- Returns:
- the value of the
failurerecord component
-