Class ChatDelta
java.lang.Object
com.sap.ai.sdk.orchestration.model.ChatDelta
ChatDelta
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddToolCallsItem(ToolCallChunk toolCallsItem) Add one toolCalls instance to thisChatDelta.Set the content of thisChatDeltainstance and return the same instance.static ChatDelta.Buildercreate()Create a type-safe, fluent-api builder object to construct a newChatDeltainstance with all required arguments.booleanGet contentgetCustomField(String name) Deprecated.Get the names of the unrecognizable properties of theChatDelta.The refusal message generated by the model.getRole()Get roleGet toolCallsinthashCode()Set the refusal of thisChatDeltainstance and return the same instance.Set the role of thisChatDeltainstance and return the same instance.voidsetContent(String content) Set the content of thisChatDeltainstance.voidsetCustomField(String customFieldName, Object customFieldValue) Set an unrecognizable property of thisChatDeltainstance.voidsetRefusal(String refusal) Set the refusal of thisChatDeltainstance.voidSet the role of thisChatDeltainstance.voidsetToolCalls(List<ToolCallChunk> toolCalls) Set the toolCalls of thisChatDeltainstance.toMap()Get the value of all properties of thisChatDeltainstance including unrecognized properties.toolCalls(List<ToolCallChunk> toolCalls) Set the toolCalls of thisChatDeltainstance and return the same instance.toString()
-
Constructor Details
-
ChatDelta
protected ChatDelta()Default constructor for ChatDelta.
-
-
Method Details
-
role
Set the role of thisChatDeltainstance and return the same instance. -
getRole
Get role- Returns:
- role The role of this
ChatDeltainstance.
-
setRole
Set the role of thisChatDeltainstance.- Parameters:
role- The role of thisChatDelta
-
content
Set the content of thisChatDeltainstance and return the same instance. -
getContent
Get content- Returns:
- content The content of this
ChatDeltainstance.
-
setContent
Set the content of thisChatDeltainstance.- Parameters:
content- The content of thisChatDelta
-
refusal
Set the refusal of thisChatDeltainstance and return the same instance.- Parameters:
refusal- The refusal message generated by the model.- Returns:
- The same instance of this
ChatDeltaclass
-
getRefusal
The refusal message generated by the model.- Returns:
- refusal The refusal of this
ChatDeltainstance.
-
setRefusal
Set the refusal of thisChatDeltainstance.- Parameters:
refusal- The refusal message generated by the model.
-
toolCalls
Set the toolCalls of thisChatDeltainstance and return the same instance. -
addToolCallsItem
Add one toolCalls instance to thisChatDelta.- Parameters:
toolCallsItem- The toolCalls that should be added- Returns:
- The same instance of type
ChatDelta
-
getToolCalls
Get toolCalls- Returns:
- toolCalls The toolCalls of this
ChatDeltainstance.
-
setToolCalls
Set the toolCalls of thisChatDeltainstance.- Parameters:
toolCalls- The toolCalls of thisChatDelta
-
getCustomFieldNames
Get the names of the unrecognizable properties of theChatDelta.- Returns:
- The set of properties names
-
getCustomField
@Nullable @Deprecated public Object getCustomField(@Nonnull String name) throws NoSuchElementException Deprecated.UsetoMap()instead.Get the value of an unrecognizable property of thisChatDeltainstance.- Parameters:
name- The name of the property- Returns:
- The value of the property
- Throws:
NoSuchElementException- If no property with the given name could be found.
-
toMap
Get the value of all properties of thisChatDeltainstance including unrecognized properties.- Returns:
- The map of all properties
-
setCustomField
Set an unrecognizable property of thisChatDeltainstance. If the map previously contained a mapping for the key, the old value is replaced by the specified value.- Parameters:
customFieldName- The name of the propertycustomFieldValue- The value of the property
-
equals
-
hashCode
public int hashCode() -
toString
-
create
Create a type-safe, fluent-api builder object to construct a newChatDeltainstance with all required arguments.
-
toMap()instead.