Class ImportProductsRequest.Builder (2.55.0)

public static final class ImportProductsRequest.Builder extends GeneratedMessageV3.Builder<ImportProductsRequest.Builder> implements ImportProductsRequestOrBuilder

Request message for Import methods.

Protobuf type google.cloud.retail.v2alpha.ImportProductsRequest

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public ImportProductsRequest build()
Returns
Type Description
ImportProductsRequest

buildPartial()

public ImportProductsRequest buildPartial()
Returns
Type Description
ImportProductsRequest

clear()

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

clearErrorsConfig()

public ImportProductsRequest.Builder clearErrorsConfig()

The desired location of errors incurred during the Import.

.google.cloud.retail.v2alpha.ImportErrorsConfig errors_config = 3;

Returns
Type Description
ImportProductsRequest.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearInputConfig()

public ImportProductsRequest.Builder clearInputConfig()

Required. The desired input location of the data.

.google.cloud.retail.v2alpha.ProductInputConfig input_config = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ImportProductsRequest.Builder

clearNotificationPubsubTopic()

public ImportProductsRequest.Builder clearNotificationPubsubTopic()

Full Pub/Sub topic name for receiving notification. If this field is set, when the import is finished, a notification is sent to specified Pub/Sub topic. The message data is JSON string of a Operation.

Format of the Pub/Sub topic is projects/{project}/topics/{topic}. It has to be within the same project as ImportProductsRequest.parent. Make sure that both cloud-retail-customer-data-access@system.gserviceaccount.com and service-<project number>@gcp-sa-retail.iam.gserviceaccount.com have the pubsub.topics.publish IAM permission on the topic.

Only supported when ImportProductsRequest.reconciliation_mode is set to FULL.

string notification_pubsub_topic = 7;

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearParent()

public ImportProductsRequest.Builder clearParent()

Required. projects/1234/locations/global/catalogs/default_catalog/branches/default_branch

If no updateMask is specified, requires products.create permission. If updateMask is specified, requires products.update permission.

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

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

clearReconciliationMode()

public ImportProductsRequest.Builder clearReconciliationMode()

The mode of reconciliation between existing products and the products to be imported. Defaults to ReconciliationMode.INCREMENTAL.

.google.cloud.retail.v2alpha.ImportProductsRequest.ReconciliationMode reconciliation_mode = 5;

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

clearRequestId() (deprecated)

public ImportProductsRequest.Builder clearRequestId()

Deprecated. google.cloud.retail.v2alpha.ImportProductsRequest.request_id is deprecated. See google/cloud/retail/v2alpha/import_config.proto;l=189

Deprecated. This field has no effect.

string request_id = 6 [deprecated = true];

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

clearSkipDefaultBranchProtection()

public ImportProductsRequest.Builder clearSkipDefaultBranchProtection()

If true, this performs the FULL import even if it would delete a large proportion of the products in the default branch, which could potentially cause outages if you have live predict/search traffic.

Only supported when ImportProductsRequest.reconciliation_mode is set to FULL.

bool skip_default_branch_protection = 8;

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

clearUpdateMask()

public ImportProductsRequest.Builder clearUpdateMask()

Indicates which fields in the provided imported products to update. If not set, all fields are updated. If provided, only the existing product fields are updated. Missing products will not be created.

.google.protobuf.FieldMask update_mask = 4;

Returns
Type Description
ImportProductsRequest.Builder

clone()

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

getDefaultInstanceForType()

public ImportProductsRequest getDefaultInstanceForType()
Returns
Type Description
ImportProductsRequest

getDescriptorForType()

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

getErrorsConfig()

public ImportErrorsConfig getErrorsConfig()

The desired location of errors incurred during the Import.

.google.cloud.retail.v2alpha.ImportErrorsConfig errors_config = 3;

Returns
Type Description
ImportErrorsConfig

The errorsConfig.

getErrorsConfigBuilder()

public ImportErrorsConfig.Builder getErrorsConfigBuilder()

The desired location of errors incurred during the Import.

.google.cloud.retail.v2alpha.ImportErrorsConfig errors_config = 3;

Returns
Type Description
ImportErrorsConfig.Builder

getErrorsConfigOrBuilder()

public ImportErrorsConfigOrBuilder getErrorsConfigOrBuilder()

The desired location of errors incurred during the Import.

.google.cloud.retail.v2alpha.ImportErrorsConfig errors_config = 3;

Returns
Type Description
ImportErrorsConfigOrBuilder

getInputConfig()

public ProductInputConfig getInputConfig()

Required. The desired input location of the data.

.google.cloud.retail.v2alpha.ProductInputConfig input_config = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ProductInputConfig

The inputConfig.

getInputConfigBuilder()

public ProductInputConfig.Builder getInputConfigBuilder()

Required. The desired input location of the data.

.google.cloud.retail.v2alpha.ProductInputConfig input_config = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ProductInputConfig.Builder

getInputConfigOrBuilder()

public ProductInputConfigOrBuilder getInputConfigOrBuilder()

Required. The desired input location of the data.

.google.cloud.retail.v2alpha.ProductInputConfig input_config = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ProductInputConfigOrBuilder

getNotificationPubsubTopic()

public String getNotificationPubsubTopic()

Full Pub/Sub topic name for receiving notification. If this field is set, when the import is finished, a notification is sent to specified Pub/Sub topic. The message data is JSON string of a Operation.

Format of the Pub/Sub topic is projects/{project}/topics/{topic}. It has to be within the same project as ImportProductsRequest.parent. Make sure that both cloud-retail-customer-data-access@system.gserviceaccount.com and service-<project number>@gcp-sa-retail.iam.gserviceaccount.com have the pubsub.topics.publish IAM permission on the topic.

Only supported when ImportProductsRequest.reconciliation_mode is set to FULL.

string notification_pubsub_topic = 7;

Returns
Type Description
String

The notificationPubsubTopic.

getNotificationPubsubTopicBytes()

public ByteString getNotificationPubsubTopicBytes()

Full Pub/Sub topic name for receiving notification. If this field is set, when the import is finished, a notification is sent to specified Pub/Sub topic. The message data is JSON string of a Operation.

Format of the Pub/Sub topic is projects/{project}/topics/{topic}. It has to be within the same project as ImportProductsRequest.parent. Make sure that both cloud-retail-customer-data-access@system.gserviceaccount.com and service-<project number>@gcp-sa-retail.iam.gserviceaccount.com have the pubsub.topics.publish IAM permission on the topic.

Only supported when ImportProductsRequest.reconciliation_mode is set to FULL.

string notification_pubsub_topic = 7;

Returns
Type Description
ByteString

The bytes for notificationPubsubTopic.

getParent()

public String getParent()

Required. projects/1234/locations/global/catalogs/default_catalog/branches/default_branch

If no updateMask is specified, requires products.create permission. If updateMask is specified, requires products.update permission.

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

Returns
Type Description
String

The parent.

getParentBytes()

public ByteString getParentBytes()

Required. projects/1234/locations/global/catalogs/default_catalog/branches/default_branch

If no updateMask is specified, requires products.create permission. If updateMask is specified, requires products.update permission.

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

Returns
Type Description
ByteString

The bytes for parent.

getReconciliationMode()

public ImportProductsRequest.ReconciliationMode getReconciliationMode()

The mode of reconciliation between existing products and the products to be imported. Defaults to ReconciliationMode.INCREMENTAL.

.google.cloud.retail.v2alpha.ImportProductsRequest.ReconciliationMode reconciliation_mode = 5;

Returns
Type Description
ImportProductsRequest.ReconciliationMode

The reconciliationMode.

getReconciliationModeValue()

public int getReconciliationModeValue()

The mode of reconciliation between existing products and the products to be imported. Defaults to ReconciliationMode.INCREMENTAL.

.google.cloud.retail.v2alpha.ImportProductsRequest.ReconciliationMode reconciliation_mode = 5;

Returns
Type Description
int

The enum numeric value on the wire for reconciliationMode.

getRequestId() (deprecated)

public String getRequestId()

Deprecated. google.cloud.retail.v2alpha.ImportProductsRequest.request_id is deprecated. See google/cloud/retail/v2alpha/import_config.proto;l=189

Deprecated. This field has no effect.

string request_id = 6 [deprecated = true];

Returns
Type Description
String

The requestId.

getRequestIdBytes() (deprecated)

public ByteString getRequestIdBytes()

Deprecated. google.cloud.retail.v2alpha.ImportProductsRequest.request_id is deprecated. See google/cloud/retail/v2alpha/import_config.proto;l=189

Deprecated. This field has no effect.

string request_id = 6 [deprecated = true];

Returns
Type Description
ByteString

The bytes for requestId.

getSkipDefaultBranchProtection()

public boolean getSkipDefaultBranchProtection()

If true, this performs the FULL import even if it would delete a large proportion of the products in the default branch, which could potentially cause outages if you have live predict/search traffic.

Only supported when ImportProductsRequest.reconciliation_mode is set to FULL.

bool skip_default_branch_protection = 8;

Returns
Type Description
boolean

The skipDefaultBranchProtection.

getUpdateMask()

public FieldMask getUpdateMask()

Indicates which fields in the provided imported products to update. If not set, all fields are updated. If provided, only the existing product fields are updated. Missing products will not be created.

.google.protobuf.FieldMask update_mask = 4;

Returns
Type Description
FieldMask

The updateMask.

getUpdateMaskBuilder()

public FieldMask.Builder getUpdateMaskBuilder()

Indicates which fields in the provided imported products to update. If not set, all fields are updated. If provided, only the existing product fields are updated. Missing products will not be created.

.google.protobuf.FieldMask update_mask = 4;

Returns
Type Description
Builder

getUpdateMaskOrBuilder()

public FieldMaskOrBuilder getUpdateMaskOrBuilder()

Indicates which fields in the provided imported products to update. If not set, all fields are updated. If provided, only the existing product fields are updated. Missing products will not be created.

.google.protobuf.FieldMask update_mask = 4;

Returns
Type Description
FieldMaskOrBuilder

hasErrorsConfig()

public boolean hasErrorsConfig()

The desired location of errors incurred during the Import.

.google.cloud.retail.v2alpha.ImportErrorsConfig errors_config = 3;

Returns
Type Description
boolean

Whether the errorsConfig field is set.

hasInputConfig()

public boolean hasInputConfig()

Required. The desired input location of the data.

.google.cloud.retail.v2alpha.ProductInputConfig input_config = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
boolean

Whether the inputConfig field is set.

hasUpdateMask()

public boolean hasUpdateMask()

Indicates which fields in the provided imported products to update. If not set, all fields are updated. If provided, only the existing product fields are updated. Missing products will not be created.

.google.protobuf.FieldMask update_mask = 4;

Returns
Type Description
boolean

Whether the updateMask field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeErrorsConfig(ImportErrorsConfig value)

public ImportProductsRequest.Builder mergeErrorsConfig(ImportErrorsConfig value)

The desired location of errors incurred during the Import.

.google.cloud.retail.v2alpha.ImportErrorsConfig errors_config = 3;

Parameter
Name Description
value ImportErrorsConfig
Returns
Type Description
ImportProductsRequest.Builder

mergeFrom(ImportProductsRequest other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeInputConfig(ProductInputConfig value)

public ImportProductsRequest.Builder mergeInputConfig(ProductInputConfig value)

Required. The desired input location of the data.

.google.cloud.retail.v2alpha.ProductInputConfig input_config = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ProductInputConfig
Returns
Type Description
ImportProductsRequest.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

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

mergeUpdateMask(FieldMask value)

public ImportProductsRequest.Builder mergeUpdateMask(FieldMask value)

Indicates which fields in the provided imported products to update. If not set, all fields are updated. If provided, only the existing product fields are updated. Missing products will not be created.

.google.protobuf.FieldMask update_mask = 4;

Parameter
Name Description
value FieldMask
Returns
Type Description
ImportProductsRequest.Builder

setErrorsConfig(ImportErrorsConfig value)

public ImportProductsRequest.Builder setErrorsConfig(ImportErrorsConfig value)

The desired location of errors incurred during the Import.

.google.cloud.retail.v2alpha.ImportErrorsConfig errors_config = 3;

Parameter
Name Description
value ImportErrorsConfig
Returns
Type Description
ImportProductsRequest.Builder

setErrorsConfig(ImportErrorsConfig.Builder builderForValue)

public ImportProductsRequest.Builder setErrorsConfig(ImportErrorsConfig.Builder builderForValue)

The desired location of errors incurred during the Import.

.google.cloud.retail.v2alpha.ImportErrorsConfig errors_config = 3;

Parameter
Name Description
builderForValue ImportErrorsConfig.Builder
Returns
Type Description
ImportProductsRequest.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setInputConfig(ProductInputConfig value)

public ImportProductsRequest.Builder setInputConfig(ProductInputConfig value)

Required. The desired input location of the data.

.google.cloud.retail.v2alpha.ProductInputConfig input_config = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ProductInputConfig
Returns
Type Description
ImportProductsRequest.Builder

setInputConfig(ProductInputConfig.Builder builderForValue)

public ImportProductsRequest.Builder setInputConfig(ProductInputConfig.Builder builderForValue)

Required. The desired input location of the data.

.google.cloud.retail.v2alpha.ProductInputConfig input_config = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
builderForValue ProductInputConfig.Builder
Returns
Type Description
ImportProductsRequest.Builder

setNotificationPubsubTopic(String value)

public ImportProductsRequest.Builder setNotificationPubsubTopic(String value)

Full Pub/Sub topic name for receiving notification. If this field is set, when the import is finished, a notification is sent to specified Pub/Sub topic. The message data is JSON string of a Operation.

Format of the Pub/Sub topic is projects/{project}/topics/{topic}. It has to be within the same project as ImportProductsRequest.parent. Make sure that both cloud-retail-customer-data-access@system.gserviceaccount.com and service-<project number>@gcp-sa-retail.iam.gserviceaccount.com have the pubsub.topics.publish IAM permission on the topic.

Only supported when ImportProductsRequest.reconciliation_mode is set to FULL.

string notification_pubsub_topic = 7;

Parameter
Name Description
value String

The notificationPubsubTopic to set.

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

setNotificationPubsubTopicBytes(ByteString value)

public ImportProductsRequest.Builder setNotificationPubsubTopicBytes(ByteString value)

Full Pub/Sub topic name for receiving notification. If this field is set, when the import is finished, a notification is sent to specified Pub/Sub topic. The message data is JSON string of a Operation.

Format of the Pub/Sub topic is projects/{project}/topics/{topic}. It has to be within the same project as ImportProductsRequest.parent. Make sure that both cloud-retail-customer-data-access@system.gserviceaccount.com and service-<project number>@gcp-sa-retail.iam.gserviceaccount.com have the pubsub.topics.publish IAM permission on the topic.

Only supported when ImportProductsRequest.reconciliation_mode is set to FULL.

string notification_pubsub_topic = 7;

Parameter
Name Description
value ByteString

The bytes for notificationPubsubTopic to set.

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

setParent(String value)

public ImportProductsRequest.Builder setParent(String value)

Required. projects/1234/locations/global/catalogs/default_catalog/branches/default_branch

If no updateMask is specified, requires products.create permission. If updateMask is specified, requires products.update permission.

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

Parameter
Name Description
value String

The parent to set.

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

setParentBytes(ByteString value)

public ImportProductsRequest.Builder setParentBytes(ByteString value)

Required. projects/1234/locations/global/catalogs/default_catalog/branches/default_branch

If no updateMask is specified, requires products.create permission. If updateMask is specified, requires products.update permission.

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

Parameter
Name Description
value ByteString

The bytes for parent to set.

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

setReconciliationMode(ImportProductsRequest.ReconciliationMode value)

public ImportProductsRequest.Builder setReconciliationMode(ImportProductsRequest.ReconciliationMode value)

The mode of reconciliation between existing products and the products to be imported. Defaults to ReconciliationMode.INCREMENTAL.

.google.cloud.retail.v2alpha.ImportProductsRequest.ReconciliationMode reconciliation_mode = 5;

Parameter
Name Description
value ImportProductsRequest.ReconciliationMode

The reconciliationMode to set.

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

setReconciliationModeValue(int value)

public ImportProductsRequest.Builder setReconciliationModeValue(int value)

The mode of reconciliation between existing products and the products to be imported. Defaults to ReconciliationMode.INCREMENTAL.

.google.cloud.retail.v2alpha.ImportProductsRequest.ReconciliationMode reconciliation_mode = 5;

Parameter
Name Description
value int

The enum numeric value on the wire for reconciliationMode to set.

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

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

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

setRequestId(String value) (deprecated)

public ImportProductsRequest.Builder setRequestId(String value)

Deprecated. google.cloud.retail.v2alpha.ImportProductsRequest.request_id is deprecated. See google/cloud/retail/v2alpha/import_config.proto;l=189

Deprecated. This field has no effect.

string request_id = 6 [deprecated = true];

Parameter
Name Description
value String

The requestId to set.

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

setRequestIdBytes(ByteString value) (deprecated)

public ImportProductsRequest.Builder setRequestIdBytes(ByteString value)

Deprecated. google.cloud.retail.v2alpha.ImportProductsRequest.request_id is deprecated. See google/cloud/retail/v2alpha/import_config.proto;l=189

Deprecated. This field has no effect.

string request_id = 6 [deprecated = true];

Parameter
Name Description
value ByteString

The bytes for requestId to set.

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

setSkipDefaultBranchProtection(boolean value)

public ImportProductsRequest.Builder setSkipDefaultBranchProtection(boolean value)

If true, this performs the FULL import even if it would delete a large proportion of the products in the default branch, which could potentially cause outages if you have live predict/search traffic.

Only supported when ImportProductsRequest.reconciliation_mode is set to FULL.

bool skip_default_branch_protection = 8;

Parameter
Name Description
value boolean

The skipDefaultBranchProtection to set.

Returns
Type Description
ImportProductsRequest.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

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

setUpdateMask(FieldMask value)

public ImportProductsRequest.Builder setUpdateMask(FieldMask value)

Indicates which fields in the provided imported products to update. If not set, all fields are updated. If provided, only the existing product fields are updated. Missing products will not be created.

.google.protobuf.FieldMask update_mask = 4;

Parameter
Name Description
value FieldMask
Returns
Type Description
ImportProductsRequest.Builder

setUpdateMask(FieldMask.Builder builderForValue)

public ImportProductsRequest.Builder setUpdateMask(FieldMask.Builder builderForValue)

Indicates which fields in the provided imported products to update. If not set, all fields are updated. If provided, only the existing product fields are updated. Missing products will not be created.

.google.protobuf.FieldMask update_mask = 4;

Parameter
Name Description
builderForValue Builder
Returns
Type Description
ImportProductsRequest.Builder