public static final class FunctionResponse.Builder extends GeneratedMessageV3.Builder<FunctionResponse.Builder> implements FunctionResponseOrBuilder
The result output from a [FunctionCall] that contains a string representing
the [FunctionDeclaration.name] and a structured JSON object containing any
output from the function is used as context to the model. This should contain
the result of a [FunctionCall] made based on model prediction.
Protobuf type google.cloud.vertexai.v1.FunctionResponse
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public FunctionResponse.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Overrides
build()
public FunctionResponse build()
buildPartial()
public FunctionResponse buildPartial()
clear()
public FunctionResponse.Builder clear()
Overrides
clearField(Descriptors.FieldDescriptor field)
public FunctionResponse.Builder clearField(Descriptors.FieldDescriptor field)
Overrides
clearName()
public FunctionResponse.Builder clearName()
Required. The name of the function to call.
Matches [FunctionDeclaration.name] and [FunctionCall.name].
string name = 1 [(.google.api.field_behavior) = REQUIRED];
clearOneof(Descriptors.OneofDescriptor oneof)
public FunctionResponse.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Overrides
clearResponse()
public FunctionResponse.Builder clearResponse()
Required. The function response in JSON object format.
.google.protobuf.Struct response = 2 [(.google.api.field_behavior) = REQUIRED];
clone()
public FunctionResponse.Builder clone()
Overrides
getDefaultInstanceForType()
public FunctionResponse getDefaultInstanceForType()
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Overrides
getName()
Required. The name of the function to call.
Matches [FunctionDeclaration.name] and [FunctionCall.name].
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
String |
The name.
|
getNameBytes()
public ByteString getNameBytes()
Required. The name of the function to call.
Matches [FunctionDeclaration.name] and [FunctionCall.name].
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
ByteString |
The bytes for name.
|
getResponse()
public Struct getResponse()
Required. The function response in JSON object format.
.google.protobuf.Struct response = 2 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
Struct |
The response.
|
getResponseBuilder()
public Struct.Builder getResponseBuilder()
Required. The function response in JSON object format.
.google.protobuf.Struct response = 2 [(.google.api.field_behavior) = REQUIRED];
getResponseOrBuilder()
public StructOrBuilder getResponseOrBuilder()
Required. The function response in JSON object format.
.google.protobuf.Struct response = 2 [(.google.api.field_behavior) = REQUIRED];
hasResponse()
public boolean hasResponse()
Required. The function response in JSON object format.
.google.protobuf.Struct response = 2 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
boolean |
Whether the response field is set.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
mergeFrom(FunctionResponse other)
public FunctionResponse.Builder mergeFrom(FunctionResponse other)
public FunctionResponse.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Overrides
mergeFrom(Message other)
public FunctionResponse.Builder mergeFrom(Message other)
Parameter |
Name |
Description |
other |
Message
|
Overrides
mergeResponse(Struct value)
public FunctionResponse.Builder mergeResponse(Struct value)
Required. The function response in JSON object format.
.google.protobuf.Struct response = 2 [(.google.api.field_behavior) = REQUIRED];
Parameter |
Name |
Description |
value |
Struct
|
mergeUnknownFields(UnknownFieldSet unknownFields)
public final FunctionResponse.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Overrides
setField(Descriptors.FieldDescriptor field, Object value)
public FunctionResponse.Builder setField(Descriptors.FieldDescriptor field, Object value)
Overrides
setName(String value)
public FunctionResponse.Builder setName(String value)
Required. The name of the function to call.
Matches [FunctionDeclaration.name] and [FunctionCall.name].
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Parameter |
Name |
Description |
value |
String
The name to set.
|
setNameBytes(ByteString value)
public FunctionResponse.Builder setNameBytes(ByteString value)
Required. The name of the function to call.
Matches [FunctionDeclaration.name] and [FunctionCall.name].
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Parameter |
Name |
Description |
value |
ByteString
The bytes for name to set.
|
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public FunctionResponse.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Overrides
setResponse(Struct value)
public FunctionResponse.Builder setResponse(Struct value)
Required. The function response in JSON object format.
.google.protobuf.Struct response = 2 [(.google.api.field_behavior) = REQUIRED];
Parameter |
Name |
Description |
value |
Struct
|
setResponse(Struct.Builder builderForValue)
public FunctionResponse.Builder setResponse(Struct.Builder builderForValue)
Required. The function response in JSON object format.
.google.protobuf.Struct response = 2 [(.google.api.field_behavior) = REQUIRED];
Parameter |
Name |
Description |
builderForValue |
Builder
|
setUnknownFields(UnknownFieldSet unknownFields)
public final FunctionResponse.Builder setUnknownFields(UnknownFieldSet unknownFields)
Overrides