Package io.hektor.fsm.impl
Record Class FsmLogContext<S extends Enum<S>>
java.lang.Object
java.lang.Record
io.hektor.fsm.impl.FsmLogContext<S>
- All Implemented Interfaces:
io.snice.logging.Context
-
Constructor Summary
ConstructorsConstructorDescriptionFsmLogContext(String friendlyName, Object uuid) Creates an instance of aFsmLogContextrecord class. -
Method Summary
Modifier and TypeMethodDescriptionvoidcopyContext(BiConsumer<String, String> visitor) Returns the value of thecurrentStaterecord component.final booleanIndicates whether some other object is "equal to" this one.event()Returns the value of theeventrecord component.static StringTODO: should probably allow to pass in their own formatting logic.Returns the value of thefriendlyNamerecord component.final inthashCode()Returns a hash code value for this object.Returns the value of thenextStaterecord component.final StringtoString()Returns a string representation of this record class.transition(S currentState, S nextState, Object event) unhandledEvent(S currentState, Object event) uuid()Returns the value of theuuidrecord component.
-
Constructor Details
-
FsmLogContext
-
FsmLogContext
Creates an instance of aFsmLogContextrecord class.- Parameters:
friendlyName- the value for thefriendlyNamerecord componentuuid- the value for theuuidrecord componentcurrentState- the value for thecurrentStaterecord componentnextState- the value for thenextStaterecord componentevent- the value for theeventrecord component
-
-
Method Details
-
transition
-
unhandledEvent
-
copyContext
- Specified by:
copyContextin interfaceio.snice.logging.Context
-
format
TODO: should probably allow to pass in their own formatting logic. -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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). -
friendlyName
Returns the value of thefriendlyNamerecord component.- Returns:
- the value of the
friendlyNamerecord component
-
uuid
Returns the value of theuuidrecord component.- Returns:
- the value of the
uuidrecord component
-
currentState
Returns the value of thecurrentStaterecord component.- Returns:
- the value of the
currentStaterecord component
-
nextState
Returns the value of thenextStaterecord component.- Returns:
- the value of the
nextStaterecord component
-
event
Returns the value of theeventrecord component.- Returns:
- the value of the
eventrecord component
-