Class MerchantCenterLink.Builder (2.39.0)

public static final class MerchantCenterLink.Builder extends GeneratedMessageV3.Builder<MerchantCenterLink.Builder> implements MerchantCenterLinkOrBuilder

Represents a link between a Merchant Center account and a branch. Once a link is established, products from the linked merchant center account will be streamed to the linked branch.

Protobuf type google.cloud.retail.v2alpha.MerchantCenterLink

Static Methods

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

public MerchantCenterLink.Builder addAllDestinations(Iterable<String> values)

String representing the destination to import for, all if left empty. List of possible values is given in Included destination. List of allowed string values: "Shopping_ads", "Buy_on_google_listings", "Display_ads", "Local_inventory _ads", "Free_listings", "Free_local_listings" NOTE: The string values are case sensitive.

repeated string destinations = 3;

Parameter
NameDescription
valuesIterable<String>

The destinations to add.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder addAllFeeds(Iterable<? extends MerchantCenterFeedFilter> values)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameter
NameDescription
valuesIterable<? extends com.google.cloud.retail.v2alpha.MerchantCenterFeedFilter>
Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterLink.Builder addDestinations(String value)

String representing the destination to import for, all if left empty. List of possible values is given in Included destination. List of allowed string values: "Shopping_ads", "Buy_on_google_listings", "Display_ads", "Local_inventory _ads", "Free_listings", "Free_local_listings" NOTE: The string values are case sensitive.

repeated string destinations = 3;

Parameter
NameDescription
valueString

The destinations to add.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder addDestinationsBytes(ByteString value)

String representing the destination to import for, all if left empty. List of possible values is given in Included destination. List of allowed string values: "Shopping_ads", "Buy_on_google_listings", "Display_ads", "Local_inventory _ads", "Free_listings", "Free_local_listings" NOTE: The string values are case sensitive.

repeated string destinations = 3;

Parameter
NameDescription
valueByteString

The bytes of the destinations to add.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder addFeeds(MerchantCenterFeedFilter value)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameter
NameDescription
valueMerchantCenterFeedFilter
Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterLink.Builder addFeeds(MerchantCenterFeedFilter.Builder builderForValue)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameter
NameDescription
builderForValueMerchantCenterFeedFilter.Builder
Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterLink.Builder addFeeds(int index, MerchantCenterFeedFilter value)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameters
NameDescription
indexint
valueMerchantCenterFeedFilter
Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterLink.Builder addFeeds(int index, MerchantCenterFeedFilter.Builder builderForValue)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameters
NameDescription
indexint
builderForValueMerchantCenterFeedFilter.Builder
Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterFeedFilter.Builder addFeedsBuilder()

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Returns
TypeDescription
MerchantCenterFeedFilter.Builder
public MerchantCenterFeedFilter.Builder addFeedsBuilder(int index)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameter
NameDescription
indexint
Returns
TypeDescription
MerchantCenterFeedFilter.Builder
public MerchantCenterLink.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
public MerchantCenterLink build()
Returns
TypeDescription
MerchantCenterLink
public MerchantCenterLink buildPartial()
Returns
TypeDescription
MerchantCenterLink
public MerchantCenterLink.Builder clear()
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
public MerchantCenterLink.Builder clearBranchId()

The branch ID (e.g. 0/1/2) within this catalog that products from merchant_center_account_id are streamed to. When updating this field, an empty value will use the currently configured default branch. However, changing the default branch later on won't change the linked branch here.

A single branch ID can only have one linked merchant center account ID.

string branch_id = 2;

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder clearDestinations()

String representing the destination to import for, all if left empty. List of possible values is given in Included destination. List of allowed string values: "Shopping_ads", "Buy_on_google_listings", "Display_ads", "Local_inventory _ads", "Free_listings", "Free_local_listings" NOTE: The string values are case sensitive.

repeated string destinations = 3;

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder clearFeeds()

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterLink.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
public MerchantCenterLink.Builder clearLanguageCode()

Language of the title/description and other string attributes. Use language tags defined by BCP 47. ISO 639-1.

This specifies the language of offers in Merchant Center that will be accepted. If empty no language filtering will be performed.

Example value: en.

string language_code = 5;

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder clearMerchantCenterAccountId()

Required. The linked Merchant center account ID. The account must be a standalone account or a sub-account of a MCA.

int64 merchant_center_account_id = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
public MerchantCenterLink.Builder clearRegionCode()

Region code of offers to accept. 2-letter Uppercase ISO 3166-1 alpha-2 code. List of values can be found here under the region tag. If left blank no region filtering will be performed.

Example value: US.

string region_code = 4;

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder clone()
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
public String getBranchId()

The branch ID (e.g. 0/1/2) within this catalog that products from merchant_center_account_id are streamed to. When updating this field, an empty value will use the currently configured default branch. However, changing the default branch later on won't change the linked branch here.

A single branch ID can only have one linked merchant center account ID.

string branch_id = 2;

Returns
TypeDescription
String

The branchId.

public ByteString getBranchIdBytes()

The branch ID (e.g. 0/1/2) within this catalog that products from merchant_center_account_id are streamed to. When updating this field, an empty value will use the currently configured default branch. However, changing the default branch later on won't change the linked branch here.

A single branch ID can only have one linked merchant center account ID.

string branch_id = 2;

Returns
TypeDescription
ByteString

The bytes for branchId.

public MerchantCenterLink getDefaultInstanceForType()
Returns
TypeDescription
MerchantCenterLink
public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides
public String getDestinations(int index)

String representing the destination to import for, all if left empty. List of possible values is given in Included destination. List of allowed string values: "Shopping_ads", "Buy_on_google_listings", "Display_ads", "Local_inventory _ads", "Free_listings", "Free_local_listings" NOTE: The string values are case sensitive.

repeated string destinations = 3;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The destinations at the given index.

public ByteString getDestinationsBytes(int index)

String representing the destination to import for, all if left empty. List of possible values is given in Included destination. List of allowed string values: "Shopping_ads", "Buy_on_google_listings", "Display_ads", "Local_inventory _ads", "Free_listings", "Free_local_listings" NOTE: The string values are case sensitive.

repeated string destinations = 3;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the destinations at the given index.

public int getDestinationsCount()

String representing the destination to import for, all if left empty. List of possible values is given in Included destination. List of allowed string values: "Shopping_ads", "Buy_on_google_listings", "Display_ads", "Local_inventory _ads", "Free_listings", "Free_local_listings" NOTE: The string values are case sensitive.

repeated string destinations = 3;

Returns
TypeDescription
int

The count of destinations.

public ProtocolStringList getDestinationsList()

String representing the destination to import for, all if left empty. List of possible values is given in Included destination. List of allowed string values: "Shopping_ads", "Buy_on_google_listings", "Display_ads", "Local_inventory _ads", "Free_listings", "Free_local_listings" NOTE: The string values are case sensitive.

repeated string destinations = 3;

Returns
TypeDescription
ProtocolStringList

A list containing the destinations.

public MerchantCenterFeedFilter getFeeds(int index)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameter
NameDescription
indexint
Returns
TypeDescription
MerchantCenterFeedFilter
public MerchantCenterFeedFilter.Builder getFeedsBuilder(int index)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameter
NameDescription
indexint
Returns
TypeDescription
MerchantCenterFeedFilter.Builder
public List<MerchantCenterFeedFilter.Builder> getFeedsBuilderList()

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Returns
TypeDescription
List<Builder>
public int getFeedsCount()

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Returns
TypeDescription
int
public List<MerchantCenterFeedFilter> getFeedsList()

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Returns
TypeDescription
List<MerchantCenterFeedFilter>
public MerchantCenterFeedFilterOrBuilder getFeedsOrBuilder(int index)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameter
NameDescription
indexint
Returns
TypeDescription
MerchantCenterFeedFilterOrBuilder
public List<? extends MerchantCenterFeedFilterOrBuilder> getFeedsOrBuilderList()

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Returns
TypeDescription
List<? extends com.google.cloud.retail.v2alpha.MerchantCenterFeedFilterOrBuilder>
public String getLanguageCode()

Language of the title/description and other string attributes. Use language tags defined by BCP 47. ISO 639-1.

This specifies the language of offers in Merchant Center that will be accepted. If empty no language filtering will be performed.

Example value: en.

string language_code = 5;

Returns
TypeDescription
String

The languageCode.

public ByteString getLanguageCodeBytes()

Language of the title/description and other string attributes. Use language tags defined by BCP 47. ISO 639-1.

This specifies the language of offers in Merchant Center that will be accepted. If empty no language filtering will be performed.

Example value: en.

string language_code = 5;

Returns
TypeDescription
ByteString

The bytes for languageCode.

public long getMerchantCenterAccountId()

Required. The linked Merchant center account ID. The account must be a standalone account or a sub-account of a MCA.

int64 merchant_center_account_id = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
long

The merchantCenterAccountId.

public String getRegionCode()

Region code of offers to accept. 2-letter Uppercase ISO 3166-1 alpha-2 code. List of values can be found here under the region tag. If left blank no region filtering will be performed.

Example value: US.

string region_code = 4;

Returns
TypeDescription
String

The regionCode.

public ByteString getRegionCodeBytes()

Region code of offers to accept. 2-letter Uppercase ISO 3166-1 alpha-2 code. List of values can be found here under the region tag. If left blank no region filtering will be performed.

Example value: US.

string region_code = 4;

Returns
TypeDescription
ByteString

The bytes for regionCode.

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides
public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides
public MerchantCenterLink.Builder mergeFrom(MerchantCenterLink other)
Parameter
NameDescription
otherMerchantCenterLink
Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterLink.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
Exceptions
TypeDescription
IOException
public MerchantCenterLink.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
public final MerchantCenterLink.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
public MerchantCenterLink.Builder removeFeeds(int index)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameter
NameDescription
indexint
Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterLink.Builder setBranchId(String value)

The branch ID (e.g. 0/1/2) within this catalog that products from merchant_center_account_id are streamed to. When updating this field, an empty value will use the currently configured default branch. However, changing the default branch later on won't change the linked branch here.

A single branch ID can only have one linked merchant center account ID.

string branch_id = 2;

Parameter
NameDescription
valueString

The branchId to set.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder setBranchIdBytes(ByteString value)

The branch ID (e.g. 0/1/2) within this catalog that products from merchant_center_account_id are streamed to. When updating this field, an empty value will use the currently configured default branch. However, changing the default branch later on won't change the linked branch here.

A single branch ID can only have one linked merchant center account ID.

string branch_id = 2;

Parameter
NameDescription
valueByteString

The bytes for branchId to set.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder setDestinations(int index, String value)

String representing the destination to import for, all if left empty. List of possible values is given in Included destination. List of allowed string values: "Shopping_ads", "Buy_on_google_listings", "Display_ads", "Local_inventory _ads", "Free_listings", "Free_local_listings" NOTE: The string values are case sensitive.

repeated string destinations = 3;

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The destinations to set.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder setFeeds(int index, MerchantCenterFeedFilter value)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameters
NameDescription
indexint
valueMerchantCenterFeedFilter
Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterLink.Builder setFeeds(int index, MerchantCenterFeedFilter.Builder builderForValue)

Criteria for the Merchant Center feeds to be ingested via the link. All offers will be ingested if the list is empty. Otherwise the offers will be ingested from selected feeds.

repeated .google.cloud.retail.v2alpha.MerchantCenterFeedFilter feeds = 6;

Parameters
NameDescription
indexint
builderForValueMerchantCenterFeedFilter.Builder
Returns
TypeDescription
MerchantCenterLink.Builder
public MerchantCenterLink.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
public MerchantCenterLink.Builder setLanguageCode(String value)

Language of the title/description and other string attributes. Use language tags defined by BCP 47. ISO 639-1.

This specifies the language of offers in Merchant Center that will be accepted. If empty no language filtering will be performed.

Example value: en.

string language_code = 5;

Parameter
NameDescription
valueString

The languageCode to set.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder setLanguageCodeBytes(ByteString value)

Language of the title/description and other string attributes. Use language tags defined by BCP 47. ISO 639-1.

This specifies the language of offers in Merchant Center that will be accepted. If empty no language filtering will be performed.

Example value: en.

string language_code = 5;

Parameter
NameDescription
valueByteString

The bytes for languageCode to set.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder setMerchantCenterAccountId(long value)

Required. The linked Merchant center account ID. The account must be a standalone account or a sub-account of a MCA.

int64 merchant_center_account_id = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valuelong

The merchantCenterAccountId to set.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder setRegionCode(String value)

Region code of offers to accept. 2-letter Uppercase ISO 3166-1 alpha-2 code. List of values can be found here under the region tag. If left blank no region filtering will be performed.

Example value: US.

string region_code = 4;

Parameter
NameDescription
valueString

The regionCode to set.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder setRegionCodeBytes(ByteString value)

Region code of offers to accept. 2-letter Uppercase ISO 3166-1 alpha-2 code. List of values can be found here under the region tag. If left blank no region filtering will be performed.

Example value: US.

string region_code = 4;

Parameter
NameDescription
valueByteString

The bytes for regionCode to set.

Returns
TypeDescription
MerchantCenterLink.Builder

This builder for chaining.

public MerchantCenterLink.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides
public final MerchantCenterLink.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
MerchantCenterLink.Builder
Overrides