Record Class TextChatMessage.TextChatMessageUser
java.lang.Object
java.lang.Record
io.quarkiverse.langchain4j.watsonx.bean.TextChatMessage.TextChatMessageUser
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.quarkiverse.langchain4j.watsonx.bean.TextChatMessage
TextChatMessage.StreamingToolFetcher, TextChatMessage.TextChatMessageAssistant, TextChatMessage.TextChatMessageSystem, TextChatMessage.TextChatMessageTool, TextChatMessage.TextChatMessageUser, TextChatMessage.TextChatParameterTool, TextChatMessage.TextChatToolCall
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncontent()
Returns the value of thecontent
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.name()
Returns the value of thename
record component.of
(dev.langchain4j.data.message.UserMessage userMessage) Creates aTextChatMessage.TextChatMessageUser
from aUserMessage
.Creates aTextChatMessage.TextChatMessageUser
.role()
Returns the value of therole
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
TextChatMessageUser
Creates an instance of aTextChatMessageUser
record class.- Parameters:
role
- the value for therole
record componentcontent
- the value for thecontent
record componentname
- the value for thename
record component
-
-
Method Details
-
of
public static TextChatMessage.TextChatMessageUser of(dev.langchain4j.data.message.UserMessage userMessage) Creates aTextChatMessage.TextChatMessageUser
from aUserMessage
.- Parameters:
systemMessage
- the user message to convert- Returns:
- the created
TextChatMessage.TextChatMessageUser
-
of
Creates aTextChatMessage.TextChatMessageUser
.- Parameters:
message
- the content of the system message to be created.- Returns:
- the created
TextChatMessage.TextChatMessageUser
.
-
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)
. -
role
Returns the value of therole
record component.- Returns:
- the value of the
role
record component
-
content
-
name
Returns the value of thename
record component.- Returns:
- the value of the
name
record component
-