Record Class MazeService.OperationOutcome
java.lang.Object
java.lang.Record
dev.despical.mazeengine.service.MazeService.OperationOutcome
- Enclosing class:
MazeService
public static record MazeService.OperationOutcome(String name, MazeService.OperationTicket ticket, MazeRecord record, Throwable error)
extends Record
Carries the terminal record or failure delivered to the operation observer.
The ticket preserves operation identity and kind. A failed planning action can have no record, while an error after world work can retain a failed record. This notification is published before the ticket future completes.
-
Constructor Summary
ConstructorsConstructorDescriptionOperationOutcome(String name, MazeService.OperationTicket ticket, MazeRecord record, Throwable error) Creates an instance of aOperationOutcomerecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.error()Returns the value of theerrorrecord component.final inthashCode()Returns a hash code value for this object.name()Returns the value of thenamerecord component.record()Returns the value of therecordrecord component.ticket()Returns the value of theticketrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
OperationOutcome
public OperationOutcome(String name, MazeService.OperationTicket ticket, MazeRecord record, Throwable error) Creates an instance of aOperationOutcomerecord class.- Parameters:
name- the value for thenamerecord componentticket- the value for theticketrecord componentrecord- the value for therecordrecord componenterror- the value for theerrorrecord 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 withObjects::equals(Object,Object). -
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
ticket
Returns the value of theticketrecord component.- Returns:
- the value of the
ticketrecord component
-
record
Returns the value of therecordrecord component.- Returns:
- the value of the
recordrecord component
-
error
Returns the value of theerrorrecord component.- Returns:
- the value of the
errorrecord component
-