Class TransactionData.Item.Builder (3.38.0)

public static final class TransactionData.Item.Builder extends GeneratedMessageV3.Builder<TransactionData.Item.Builder> implements TransactionData.ItemOrBuilder

Line items being purchased in this transaction.

Protobuf type google.cloud.recaptchaenterprise.v1.TransactionData.Item

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public TransactionData.Item.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

build()

public TransactionData.Item build()
Returns
TypeDescription
TransactionData.Item

buildPartial()

public TransactionData.Item buildPartial()
Returns
TypeDescription
TransactionData.Item

clear()

public TransactionData.Item.Builder clear()
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public TransactionData.Item.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

clearMerchantAccountId()

public TransactionData.Item.Builder clearMerchantAccountId()

Optional. When a merchant is specified, its corresponding account_id. Necessary to populate marketplace-style transactions.

string merchant_account_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.

clearName()

public TransactionData.Item.Builder clearName()

Optional. The full name of the item.

string name = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public TransactionData.Item.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

clearQuantity()

public TransactionData.Item.Builder clearQuantity()

Optional. The quantity of this item that is being purchased.

int64 quantity = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.

clearValue()

public TransactionData.Item.Builder clearValue()

Optional. The value per item that the user is paying, in the transaction currency, after discounts.

double value = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.

clone()

public TransactionData.Item.Builder clone()
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

getDefaultInstanceForType()

public TransactionData.Item getDefaultInstanceForType()
Returns
TypeDescription
TransactionData.Item

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getMerchantAccountId()

public String getMerchantAccountId()

Optional. When a merchant is specified, its corresponding account_id. Necessary to populate marketplace-style transactions.

string merchant_account_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
String

The merchantAccountId.

getMerchantAccountIdBytes()

public ByteString getMerchantAccountIdBytes()

Optional. When a merchant is specified, its corresponding account_id. Necessary to populate marketplace-style transactions.

string merchant_account_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The bytes for merchantAccountId.

getName()

public String getName()

Optional. The full name of the item.

string name = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

Optional. The full name of the item.

string name = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ByteString

The bytes for name.

getQuantity()

public long getQuantity()

Optional. The quantity of this item that is being purchased.

int64 quantity = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
long

The quantity.

getValue()

public double getValue()

Optional. The value per item that the user is paying, in the transaction currency, after discounts.

double value = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
double

The value.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public TransactionData.Item.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
TransactionData.Item.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public TransactionData.Item.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

mergeFrom(TransactionData.Item other)

public TransactionData.Item.Builder mergeFrom(TransactionData.Item other)
Parameter
NameDescription
otherTransactionData.Item
Returns
TypeDescription
TransactionData.Item.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final TransactionData.Item.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public TransactionData.Item.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

setMerchantAccountId(String value)

public TransactionData.Item.Builder setMerchantAccountId(String value)

Optional. When a merchant is specified, its corresponding account_id. Necessary to populate marketplace-style transactions.

string merchant_account_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueString

The merchantAccountId to set.

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.

setMerchantAccountIdBytes(ByteString value)

public TransactionData.Item.Builder setMerchantAccountIdBytes(ByteString value)

Optional. When a merchant is specified, its corresponding account_id. Necessary to populate marketplace-style transactions.

string merchant_account_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueByteString

The bytes for merchantAccountId to set.

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.

setName(String value)

public TransactionData.Item.Builder setName(String value)

Optional. The full name of the item.

string name = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.

setNameBytes(ByteString value)

public TransactionData.Item.Builder setNameBytes(ByteString value)

Optional. The full name of the item.

string name = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.

setQuantity(long value)

public TransactionData.Item.Builder setQuantity(long value)

Optional. The quantity of this item that is being purchased.

int64 quantity = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valuelong

The quantity to set.

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.

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

public TransactionData.Item.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final TransactionData.Item.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
TransactionData.Item.Builder
Overrides

setValue(double value)

public TransactionData.Item.Builder setValue(double value)

Optional. The value per item that the user is paying, in the transaction currency, after discounts.

double value = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valuedouble

The value to set.

Returns
TypeDescription
TransactionData.Item.Builder

This builder for chaining.