Package com.github.copilot.sdk.events
Record Class AssistantMessageEvent.AssistantMessageData
java.lang.Object
java.lang.Record
com.github.copilot.sdk.events.AssistantMessageEvent.AssistantMessageData
- Enclosing class:
- AssistantMessageEvent
public static record AssistantMessageEvent.AssistantMessageData(String messageId, String content, List<AssistantMessageEvent.AssistantMessageData.ToolRequest> toolRequests, String parentToolCallId, String reasoningOpaque, String reasoningText, String encryptedContent)
extends Record
Contains the assistant message content and metadata.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordRepresents a request from the assistant to invoke a tool. -
Constructor Summary
ConstructorsConstructorDescriptionAssistantMessageData(String messageId, String content, List<AssistantMessageEvent.AssistantMessageData.ToolRequest> toolRequests, String parentToolCallId, String reasoningOpaque, String reasoningText, String encryptedContent) Creates an instance of aAssistantMessageDatarecord class. -
Method Summary
Modifier and TypeMethodDescriptioncontent()Returns the value of thecontentrecord component.Returns the value of theencryptedContentrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of themessageIdrecord component.Returns the value of theparentToolCallIdrecord component.Returns the value of thereasoningOpaquerecord component.Returns the value of thereasoningTextrecord component.Returns a defensive copy of the tool requests list.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
AssistantMessageData
public AssistantMessageData(String messageId, String content, List<AssistantMessageEvent.AssistantMessageData.ToolRequest> toolRequests, String parentToolCallId, String reasoningOpaque, String reasoningText, String encryptedContent) Creates an instance of aAssistantMessageDatarecord class.- Parameters:
messageId- the value for themessageIdrecord componentcontent- the value for thecontentrecord componenttoolRequests- the value for thetoolRequestsrecord componentparentToolCallId- the value for theparentToolCallIdrecord componentreasoningOpaque- the value for thereasoningOpaquerecord componentreasoningText- the value for thereasoningTextrecord componentencryptedContent- the value for theencryptedContentrecord component
-
-
Method Details
-
toolRequests
Returns a defensive copy of the tool requests list. -
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). -
messageId
Returns the value of themessageIdrecord component.- Returns:
- the value of the
messageIdrecord component
-
content
Returns the value of thecontentrecord component.- Returns:
- the value of the
contentrecord component
-
parentToolCallId
Returns the value of theparentToolCallIdrecord component.- Returns:
- the value of the
parentToolCallIdrecord component
-
reasoningOpaque
Returns the value of thereasoningOpaquerecord component.- Returns:
- the value of the
reasoningOpaquerecord component
-
reasoningText
Returns the value of thereasoningTextrecord component.- Returns:
- the value of the
reasoningTextrecord component
-
encryptedContent
Returns the value of theencryptedContentrecord component.- Returns:
- the value of the
encryptedContentrecord component
-