Record Class AuditedAspectTest.SamplePayload
java.lang.Object
java.lang.Record
ubic.gemma.core.security.audit.AuditedAspectTest.SamplePayload
- All Implemented Interfaces:
AuditEventPayload
- Enclosing class:
AuditedAspectTest
public static record AuditedAspectTest.SamplePayload(int removed, String reason)
extends Record
implements AuditEventPayload
A locally-defined payload record. Real Phase B payloads will live next
to their event types under
ubic.gemma.core.security.audit or a
dedicated package. @JsonTypeName is required on nested records
because Jackson's default discriminator includes the enclosing
class (e.g. AuditedAspectTest$SamplePayload); top-level Phase B
records won't need the annotation since their simple class name
already discriminates uniquely.-
Nested Class Summary
Nested classes/interfaces inherited from interface AuditEventPayload
AuditEventPayload.None -
Constructor Summary
ConstructorsConstructorDescriptionSamplePayload(int removed, String reason) Creates an instance of aSamplePayloadrecord 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.intremoved()Returns the value of theremovedrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SamplePayload
Creates an instance of aSamplePayloadrecord class.- Parameters:
removed- the value for theremovedrecord componentreason- the value for thereasonrecord 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. -
removed
public int removed()Returns the value of theremovedrecord component.- Returns:
- the value of the
removedrecord component
-
reason
Returns the value of thereasonrecord component.- Returns:
- the value of the
reasonrecord component
-