Class ToolCallResult.Builder (0.94.0)

public static final class ToolCallResult.Builder extends GeneratedMessage.Builder<ToolCallResult.Builder> implements ToolCallResultOrBuilder

The result of calling a tool's action that has been executed by the client.

Protobuf type google.cloud.dialogflow.cx.v3.ToolCallResult

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

build()

public ToolCallResult build()
Returns
Type Description
ToolCallResult

buildPartial()

public ToolCallResult buildPartial()
Returns
Type Description
ToolCallResult

clear()

public ToolCallResult.Builder clear()
Returns
Type Description
ToolCallResult.Builder
Overrides

clearAction()

public ToolCallResult.Builder clearAction()

Required. The name of the tool's action associated with this call.

string action = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ToolCallResult.Builder

This builder for chaining.

clearError()

public ToolCallResult.Builder clearError()

The tool call's error.

.google.cloud.dialogflow.cx.v3.ToolCallResult.Error error = 3;

Returns
Type Description
ToolCallResult.Builder

clearOutputParameters()

public ToolCallResult.Builder clearOutputParameters()

The tool call's output parameters.

.google.protobuf.Struct output_parameters = 4;

Returns
Type Description
ToolCallResult.Builder

clearResult()

public ToolCallResult.Builder clearResult()
Returns
Type Description
ToolCallResult.Builder

clearTool()

public ToolCallResult.Builder clearTool()

Required. The tool associated with this call. Format: projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/tools/<ToolID>.

string tool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
ToolCallResult.Builder

This builder for chaining.

getAction()

public String getAction()

Required. The name of the tool's action associated with this call.

string action = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The action.

getActionBytes()

public ByteString getActionBytes()

Required. The name of the tool's action associated with this call.

string action = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for action.

getDefaultInstanceForType()

public ToolCallResult getDefaultInstanceForType()
Returns
Type Description
ToolCallResult

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getError()

public ToolCallResult.Error getError()

The tool call's error.

.google.cloud.dialogflow.cx.v3.ToolCallResult.Error error = 3;

Returns
Type Description
ToolCallResult.Error

The error.

getErrorBuilder()

public ToolCallResult.Error.Builder getErrorBuilder()

The tool call's error.

.google.cloud.dialogflow.cx.v3.ToolCallResult.Error error = 3;

Returns
Type Description
ToolCallResult.Error.Builder

getErrorOrBuilder()

public ToolCallResult.ErrorOrBuilder getErrorOrBuilder()

The tool call's error.

.google.cloud.dialogflow.cx.v3.ToolCallResult.Error error = 3;

Returns
Type Description
ToolCallResult.ErrorOrBuilder

getOutputParameters()

public Struct getOutputParameters()

The tool call's output parameters.

.google.protobuf.Struct output_parameters = 4;

Returns
Type Description
Struct

The outputParameters.

getOutputParametersBuilder()

public Struct.Builder getOutputParametersBuilder()

The tool call's output parameters.

.google.protobuf.Struct output_parameters = 4;

Returns
Type Description
Builder

getOutputParametersOrBuilder()

public StructOrBuilder getOutputParametersOrBuilder()

The tool call's output parameters.

.google.protobuf.Struct output_parameters = 4;

Returns
Type Description
StructOrBuilder

getResultCase()

public ToolCallResult.ResultCase getResultCase()
Returns
Type Description
ToolCallResult.ResultCase

getTool()

public String getTool()

Required. The tool associated with this call. Format: projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/tools/<ToolID>.

string tool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
String

The tool.

getToolBytes()

public ByteString getToolBytes()

Required. The tool associated with this call. Format: projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/tools/<ToolID>.

string tool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
ByteString

The bytes for tool.

hasError()

public boolean hasError()

The tool call's error.

.google.cloud.dialogflow.cx.v3.ToolCallResult.Error error = 3;

Returns
Type Description
boolean

Whether the error field is set.

hasOutputParameters()

public boolean hasOutputParameters()

The tool call's output parameters.

.google.protobuf.Struct output_parameters = 4;

Returns
Type Description
boolean

Whether the outputParameters field is set.

internalGetFieldAccessorTable()

protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeError(ToolCallResult.Error value)

public ToolCallResult.Builder mergeError(ToolCallResult.Error value)

The tool call's error.

.google.cloud.dialogflow.cx.v3.ToolCallResult.Error error = 3;

Parameter
Name Description
value ToolCallResult.Error
Returns
Type Description
ToolCallResult.Builder

mergeFrom(ToolCallResult other)

public ToolCallResult.Builder mergeFrom(ToolCallResult other)
Parameter
Name Description
other ToolCallResult
Returns
Type Description
ToolCallResult.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public ToolCallResult.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
ToolCallResult.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public ToolCallResult.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
ToolCallResult.Builder
Overrides

mergeOutputParameters(Struct value)

public ToolCallResult.Builder mergeOutputParameters(Struct value)

The tool call's output parameters.

.google.protobuf.Struct output_parameters = 4;

Parameter
Name Description
value Struct
Returns
Type Description
ToolCallResult.Builder

setAction(String value)

public ToolCallResult.Builder setAction(String value)

Required. The name of the tool's action associated with this call.

string action = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The action to set.

Returns
Type Description
ToolCallResult.Builder

This builder for chaining.

setActionBytes(ByteString value)

public ToolCallResult.Builder setActionBytes(ByteString value)

Required. The name of the tool's action associated with this call.

string action = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for action to set.

Returns
Type Description
ToolCallResult.Builder

This builder for chaining.

setError(ToolCallResult.Error value)

public ToolCallResult.Builder setError(ToolCallResult.Error value)

The tool call's error.

.google.cloud.dialogflow.cx.v3.ToolCallResult.Error error = 3;

Parameter
Name Description
value ToolCallResult.Error
Returns
Type Description
ToolCallResult.Builder

setError(ToolCallResult.Error.Builder builderForValue)

public ToolCallResult.Builder setError(ToolCallResult.Error.Builder builderForValue)

The tool call's error.

.google.cloud.dialogflow.cx.v3.ToolCallResult.Error error = 3;

Parameter
Name Description
builderForValue ToolCallResult.Error.Builder
Returns
Type Description
ToolCallResult.Builder

setOutputParameters(Struct value)

public ToolCallResult.Builder setOutputParameters(Struct value)

The tool call's output parameters.

.google.protobuf.Struct output_parameters = 4;

Parameter
Name Description
value Struct
Returns
Type Description
ToolCallResult.Builder

setOutputParameters(Struct.Builder builderForValue)

public ToolCallResult.Builder setOutputParameters(Struct.Builder builderForValue)

The tool call's output parameters.

.google.protobuf.Struct output_parameters = 4;

Parameter
Name Description
builderForValue Builder
Returns
Type Description
ToolCallResult.Builder

setTool(String value)

public ToolCallResult.Builder setTool(String value)

Required. The tool associated with this call. Format: projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/tools/<ToolID>.

string tool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The tool to set.

Returns
Type Description
ToolCallResult.Builder

This builder for chaining.

setToolBytes(ByteString value)

public ToolCallResult.Builder setToolBytes(ByteString value)

Required. The tool associated with this call. Format: projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/tools/<ToolID>.

string tool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes for tool to set.

Returns
Type Description
ToolCallResult.Builder

This builder for chaining.