Record Class SessionEvent.CancelEvent
java.lang.Object
java.lang.Record
dev.tachyonmcp.core.server.session.SessionEvent.CancelEvent
- Record Components:
sessionId- the session this event belongs torequestId- the request identifier being cancelledtimestamp- the event timestamp (epoch millis)
- All Implemented Interfaces:
SessionEvent
- Enclosing interface:
SessionEvent
public static record SessionEvent.CancelEvent(String sessionId, RequestId requestId, long timestamp)
extends Record
implements SessionEvent
A cancellation request.
-
Nested Class Summary
Nested classes/interfaces inherited from interface dev.tachyonmcp.core.server.session.SessionEvent
SessionEvent.CancelEvent, SessionEvent.NotificationEvent, SessionEvent.OutboundRequestEvent, SessionEvent.RequestEvent, SessionEvent.ResponseEvent -
Constructor Summary
ConstructorsConstructorDescriptionCancelEvent(String sessionId, RequestId requestId, long timestamp) Creates an instance of aCancelEventrecord 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.Returns the value of therequestIdrecord component.Returns the value of thesessionIdrecord component.longReturns the value of thetimestamprecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface dev.tachyonmcp.core.server.session.SessionEvent
sseEventId, streamKey
-
Constructor Details
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
sessionId
Returns the value of thesessionIdrecord component.- Specified by:
sessionIdin interfaceSessionEvent- Returns:
- the value of the
sessionIdrecord component
-
requestId
Returns the value of therequestIdrecord component.- Returns:
- the value of the
requestIdrecord component
-
timestamp
public long timestamp()Returns the value of thetimestamprecord component.- Specified by:
timestampin interfaceSessionEvent- Returns:
- the value of the
timestamprecord component
-