Package com.google.genkit.ai.agent
Class TurnEnd
java.lang.Object
com.google.genkit.ai.agent.TurnEnd
TurnEnd signals the end of an agent turn in a streaming response.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic TurnEnd.Builderbuilder()Creates a builder for TurnEnd.Returns the finish reason.Returns the snapshot ID.voidsetFinishReason(AgentFinishReason finishReason) Sets the finish reason.voidsetSnapshotId(String snapshotId) Sets the snapshot ID.
-
Constructor Details
-
TurnEnd
public TurnEnd()Default constructor.
-
-
Method Details
-
builder
Creates a builder for TurnEnd.- Returns:
- a new builder
-
getSnapshotId
Returns the snapshot ID.- Returns:
- the snapshot ID
-
setSnapshotId
Sets the snapshot ID.- Parameters:
snapshotId- the snapshot ID
-
getFinishReason
Returns the finish reason.- Returns:
- the finish reason
-
setFinishReason
Sets the finish reason.- Parameters:
finishReason- the finish reason
-