Class AIInference.Builder (1.145.0)

public static final class AIInference.Builder extends GeneratedMessageV3.Builder<AIInference.Builder> implements AIInferenceOrBuilder

Configuration for making inference requests against Vertex AI models.

Protobuf type google.pubsub.v1.AIInference

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public AIInference.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
AIInference.Builder
Overrides

build()

public AIInference build()
Returns
Type Description
AIInference

buildPartial()

public AIInference buildPartial()
Returns
Type Description
AIInference

clear()

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

clearEndpoint()

public AIInference.Builder clearEndpoint()

Required. An endpoint to a Vertex AI model of the form projects/{project}/locations/{location}/endpoints/{endpoint} or projects/{project}/locations/{location}/publishers/{publisher}/models/{model}. Vertex AI API requests will be sent to this endpoint.

string endpoint = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
AIInference.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public AIInference.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
AIInference.Builder
Overrides

clearInferenceMode()

public AIInference.Builder clearInferenceMode()
Returns
Type Description
AIInference.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

public AIInference.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
AIInference.Builder
Overrides

clearServiceAccountEmail()

public AIInference.Builder clearServiceAccountEmail()

Optional. The service account to use to make prediction requests against endpoints. The resource creator or updater that specifies this field must have iam.serviceAccounts.actAs permission on the service account. If not specified, the Pub/Sub service agent, service-{project_number}@gcp-sa-pubsub.iam.gserviceaccount.com, is used.

string service_account_email = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AIInference.Builder

This builder for chaining.

clearUnstructuredInference()

public AIInference.Builder clearUnstructuredInference()

Optional. Requests and responses can be any arbitrary JSON object.

.google.pubsub.v1.AIInference.UnstructuredInference unstructured_inference = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AIInference.Builder

clone()

public AIInference.Builder clone()
Returns
Type Description
AIInference.Builder
Overrides

getDefaultInstanceForType()

public AIInference getDefaultInstanceForType()
Returns
Type Description
AIInference

getDescriptorForType()

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

getEndpoint()

public String getEndpoint()

Required. An endpoint to a Vertex AI model of the form projects/{project}/locations/{location}/endpoints/{endpoint} or projects/{project}/locations/{location}/publishers/{publisher}/models/{model}. Vertex AI API requests will be sent to this endpoint.

string endpoint = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The endpoint.

getEndpointBytes()

public ByteString getEndpointBytes()

Required. An endpoint to a Vertex AI model of the form projects/{project}/locations/{location}/endpoints/{endpoint} or projects/{project}/locations/{location}/publishers/{publisher}/models/{model}. Vertex AI API requests will be sent to this endpoint.

string endpoint = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for endpoint.

getInferenceModeCase()

public AIInference.InferenceModeCase getInferenceModeCase()
Returns
Type Description
AIInference.InferenceModeCase

getServiceAccountEmail()

public String getServiceAccountEmail()

Optional. The service account to use to make prediction requests against endpoints. The resource creator or updater that specifies this field must have iam.serviceAccounts.actAs permission on the service account. If not specified, the Pub/Sub service agent, service-{project_number}@gcp-sa-pubsub.iam.gserviceaccount.com, is used.

string service_account_email = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The serviceAccountEmail.

getServiceAccountEmailBytes()

public ByteString getServiceAccountEmailBytes()

Optional. The service account to use to make prediction requests against endpoints. The resource creator or updater that specifies this field must have iam.serviceAccounts.actAs permission on the service account. If not specified, the Pub/Sub service agent, service-{project_number}@gcp-sa-pubsub.iam.gserviceaccount.com, is used.

string service_account_email = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for serviceAccountEmail.

getUnstructuredInference()

public AIInference.UnstructuredInference getUnstructuredInference()

Optional. Requests and responses can be any arbitrary JSON object.

.google.pubsub.v1.AIInference.UnstructuredInference unstructured_inference = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AIInference.UnstructuredInference

The unstructuredInference.

getUnstructuredInferenceBuilder()

public AIInference.UnstructuredInference.Builder getUnstructuredInferenceBuilder()

Optional. Requests and responses can be any arbitrary JSON object.

.google.pubsub.v1.AIInference.UnstructuredInference unstructured_inference = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AIInference.UnstructuredInference.Builder

getUnstructuredInferenceOrBuilder()

public AIInference.UnstructuredInferenceOrBuilder getUnstructuredInferenceOrBuilder()

Optional. Requests and responses can be any arbitrary JSON object.

.google.pubsub.v1.AIInference.UnstructuredInference unstructured_inference = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
AIInference.UnstructuredInferenceOrBuilder

hasUnstructuredInference()

public boolean hasUnstructuredInference()

Optional. Requests and responses can be any arbitrary JSON object.

.google.pubsub.v1.AIInference.UnstructuredInference unstructured_inference = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the unstructuredInference field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeFrom(AIInference other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

public final AIInference.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
AIInference.Builder
Overrides

mergeUnstructuredInference(AIInference.UnstructuredInference value)

public AIInference.Builder mergeUnstructuredInference(AIInference.UnstructuredInference value)

Optional. Requests and responses can be any arbitrary JSON object.

.google.pubsub.v1.AIInference.UnstructuredInference unstructured_inference = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value AIInference.UnstructuredInference
Returns
Type Description
AIInference.Builder

setEndpoint(String value)

public AIInference.Builder setEndpoint(String value)

Required. An endpoint to a Vertex AI model of the form projects/{project}/locations/{location}/endpoints/{endpoint} or projects/{project}/locations/{location}/publishers/{publisher}/models/{model}. Vertex AI API requests will be sent to this endpoint.

string endpoint = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The endpoint to set.

Returns
Type Description
AIInference.Builder

This builder for chaining.

setEndpointBytes(ByteString value)

public AIInference.Builder setEndpointBytes(ByteString value)

Required. An endpoint to a Vertex AI model of the form projects/{project}/locations/{location}/endpoints/{endpoint} or projects/{project}/locations/{location}/publishers/{publisher}/models/{model}. Vertex AI API requests will be sent to this endpoint.

string endpoint = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for endpoint to set.

Returns
Type Description
AIInference.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public AIInference.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
AIInference.Builder
Overrides

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public AIInference.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
AIInference.Builder
Overrides

setServiceAccountEmail(String value)

public AIInference.Builder setServiceAccountEmail(String value)

Optional. The service account to use to make prediction requests against endpoints. The resource creator or updater that specifies this field must have iam.serviceAccounts.actAs permission on the service account. If not specified, the Pub/Sub service agent, service-{project_number}@gcp-sa-pubsub.iam.gserviceaccount.com, is used.

string service_account_email = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The serviceAccountEmail to set.

Returns
Type Description
AIInference.Builder

This builder for chaining.

setServiceAccountEmailBytes(ByteString value)

public AIInference.Builder setServiceAccountEmailBytes(ByteString value)

Optional. The service account to use to make prediction requests against endpoints. The resource creator or updater that specifies this field must have iam.serviceAccounts.actAs permission on the service account. If not specified, the Pub/Sub service agent, service-{project_number}@gcp-sa-pubsub.iam.gserviceaccount.com, is used.

string service_account_email = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for serviceAccountEmail to set.

Returns
Type Description
AIInference.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final AIInference.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
AIInference.Builder
Overrides

setUnstructuredInference(AIInference.UnstructuredInference value)

public AIInference.Builder setUnstructuredInference(AIInference.UnstructuredInference value)

Optional. Requests and responses can be any arbitrary JSON object.

.google.pubsub.v1.AIInference.UnstructuredInference unstructured_inference = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value AIInference.UnstructuredInference
Returns
Type Description
AIInference.Builder

setUnstructuredInference(AIInference.UnstructuredInference.Builder builderForValue)

public AIInference.Builder setUnstructuredInference(AIInference.UnstructuredInference.Builder builderForValue)

Optional. Requests and responses can be any arbitrary JSON object.

.google.pubsub.v1.AIInference.UnstructuredInference unstructured_inference = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue AIInference.UnstructuredInference.Builder
Returns
Type Description
AIInference.Builder