Record Class DelegationChain.Entry
java.lang.Object
java.lang.Record
com.tnsai.coordination.groups.hierarchy.DelegationChain.Entry
- Record Components:
fromAgentId- source agenttoAgentId- target agenttask- task descriptiontype- delegation or escalationtimestamp- when it occurred
- Enclosing class:
DelegationChain
public static record DelegationChain.Entry(String fromAgentId, String toAgentId, String task, DelegationChain.Type type, Instant timestamp)
extends Record
A single delegation/escalation entry.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.Returns the value of thefromAgentIdrecord component.final inthashCode()Returns a hash code value for this object.task()Returns the value of thetaskrecord component.Returns the value of thetimestamprecord component.Returns the value of thetoAgentIdrecord component.final StringtoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.
-
Constructor Details
-
Entry
public Entry(String fromAgentId, String toAgentId, String task, DelegationChain.Type type, Instant timestamp) Creates an instance of aEntryrecord class.- Parameters:
fromAgentId- the value for thefromAgentIdrecord componenttoAgentId- the value for thetoAgentIdrecord componenttask- the value for thetaskrecord componenttype- the value for thetyperecord componenttimestamp- the value for thetimestamprecord component
-
-
Method Details
-
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). -
fromAgentId
Returns the value of thefromAgentIdrecord component.- Returns:
- the value of the
fromAgentIdrecord component
-
toAgentId
Returns the value of thetoAgentIdrecord component.- Returns:
- the value of the
toAgentIdrecord component
-
task
Returns the value of thetaskrecord component.- Returns:
- the value of the
taskrecord component
-
type
Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-
timestamp
Returns the value of thetimestamprecord component.- Returns:
- the value of the
timestamprecord component
-