- 2.56.0 (latest)
- 2.55.0
- 2.54.0
- 2.53.0
- 2.51.0
- 2.50.0
- 2.49.0
- 2.48.0
- 2.47.0
- 2.46.0
- 2.45.0
- 2.44.0
- 2.43.0
- 2.42.0
- 2.41.0
- 2.39.0
- 2.38.0
- 2.37.0
- 2.36.0
- 2.35.0
- 2.34.0
- 2.33.0
- 2.32.0
- 2.31.0
- 2.30.0
- 2.29.0
- 2.26.0
- 2.25.0
- 2.24.0
- 2.23.0
- 2.22.0
- 2.21.0
- 2.20.0
- 2.19.0
- 2.18.0
- 2.17.0
- 2.16.0
- 2.15.0
- 2.14.0
- 2.13.0
- 2.11.0
- 2.10.0
- 2.9.0
- 2.8.0
- 2.7.0
- 2.6.0
- 2.5.1
- 2.4.0
- 2.3.0
- 2.2.3
- 2.1.0
- 2.0.19
public static final class PriceInfo.Builder extends GeneratedMessageV3.Builder<PriceInfo.Builder> implements PriceInfoOrBuilder
The price information of a Product.
Protobuf type google.cloud.retail.v2alpha.PriceInfo
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > PriceInfo.BuilderImplements
PriceInfoOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Type | Description |
Descriptor |
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public PriceInfo.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Name | Description |
field | FieldDescriptor |
value | Object |
Type | Description |
PriceInfo.Builder |
build()
public PriceInfo build()
Type | Description |
PriceInfo |
buildPartial()
public PriceInfo buildPartial()
Type | Description |
PriceInfo |
clear()
public PriceInfo.Builder clear()
Type | Description |
PriceInfo.Builder |
clearCost()
public PriceInfo.Builder clearCost()
The costs associated with the sale of a particular product. Used for gross profit reporting.
- Profit = price - cost Google Merchant Center property cost_of_goods_sold.
float cost = 4;
Type | Description |
PriceInfo.Builder | This builder for chaining. |
clearCurrencyCode()
public PriceInfo.Builder clearCurrencyCode()
The 3-letter currency code defined in ISO 4217. If this field is an unrecognizable currency code, an INVALID_ARGUMENT error is returned. The Product.Type.VARIANT Products with the same Product.primary_product_id must share the same currency_code. Otherwise, a FAILED_PRECONDITION error is returned.
string currency_code = 1;
Type | Description |
PriceInfo.Builder | This builder for chaining. |
clearField(Descriptors.FieldDescriptor field)
public PriceInfo.Builder clearField(Descriptors.FieldDescriptor field)
Name | Description |
field | FieldDescriptor |
Type | Description |
PriceInfo.Builder |
clearOneof(Descriptors.OneofDescriptor oneof)
public PriceInfo.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Name | Description |
oneof | OneofDescriptor |
Type | Description |
PriceInfo.Builder |
clearOriginalPrice()
public PriceInfo.Builder clearOriginalPrice()
Price of the product without any discount. If zero, by default set to be the price.
float original_price = 3;
Type | Description |
PriceInfo.Builder | This builder for chaining. |
clearPrice()
public PriceInfo.Builder clearPrice()
Price of the product. Google Merchant Center property price. Schema.org property Offer.price.
float price = 2;
Type | Description |
PriceInfo.Builder | This builder for chaining. |
clearPriceEffectiveTime()
public PriceInfo.Builder clearPriceEffectiveTime()
The timestamp when the price starts to be effective. This can be set as a future timestamp, and the price is only used for search after price_effective_time. If so, the original_price must be set and original_price is used before price_effective_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_effective_time = 5;
Type | Description |
PriceInfo.Builder |
clearPriceExpireTime()
public PriceInfo.Builder clearPriceExpireTime()
The timestamp when the price stops to be effective. The price is used for search before price_expire_time. If this field is set, the original_price must be set and original_price is used after price_expire_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_expire_time = 6;
Type | Description |
PriceInfo.Builder |
clearPriceRange()
public PriceInfo.Builder clearPriceRange()
Output only. The price range of all the child Product.Type.VARIANT Products grouped together on the Product.Type.PRIMARY Product. Only populated for Product.Type.PRIMARY Products. Note: This field is OUTPUT_ONLY for ProductService.GetProduct. Do not set this field in API requests.
.google.cloud.retail.v2alpha.PriceInfo.PriceRange price_range = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
PriceInfo.Builder |
clone()
public PriceInfo.Builder clone()
Type | Description |
PriceInfo.Builder |
getCost()
public float getCost()
The costs associated with the sale of a particular product. Used for gross profit reporting.
- Profit = price - cost Google Merchant Center property cost_of_goods_sold.
float cost = 4;
Type | Description |
float | The cost. |
getCurrencyCode()
public String getCurrencyCode()
The 3-letter currency code defined in ISO 4217. If this field is an unrecognizable currency code, an INVALID_ARGUMENT error is returned. The Product.Type.VARIANT Products with the same Product.primary_product_id must share the same currency_code. Otherwise, a FAILED_PRECONDITION error is returned.
string currency_code = 1;
Type | Description |
String | The currencyCode. |
getCurrencyCodeBytes()
public ByteString getCurrencyCodeBytes()
The 3-letter currency code defined in ISO 4217. If this field is an unrecognizable currency code, an INVALID_ARGUMENT error is returned. The Product.Type.VARIANT Products with the same Product.primary_product_id must share the same currency_code. Otherwise, a FAILED_PRECONDITION error is returned.
string currency_code = 1;
Type | Description |
ByteString | The bytes for currencyCode. |
getDefaultInstanceForType()
public PriceInfo getDefaultInstanceForType()
Type | Description |
PriceInfo |
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Type | Description |
Descriptor |
getOriginalPrice()
public float getOriginalPrice()
Price of the product without any discount. If zero, by default set to be the price.
float original_price = 3;
Type | Description |
float | The originalPrice. |
getPrice()
public float getPrice()
Price of the product. Google Merchant Center property price. Schema.org property Offer.price.
float price = 2;
Type | Description |
float | The price. |
getPriceEffectiveTime()
public Timestamp getPriceEffectiveTime()
The timestamp when the price starts to be effective. This can be set as a future timestamp, and the price is only used for search after price_effective_time. If so, the original_price must be set and original_price is used before price_effective_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_effective_time = 5;
Type | Description |
Timestamp | The priceEffectiveTime. |
getPriceEffectiveTimeBuilder()
public Timestamp.Builder getPriceEffectiveTimeBuilder()
The timestamp when the price starts to be effective. This can be set as a future timestamp, and the price is only used for search after price_effective_time. If so, the original_price must be set and original_price is used before price_effective_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_effective_time = 5;
Type | Description |
Builder |
getPriceEffectiveTimeOrBuilder()
public TimestampOrBuilder getPriceEffectiveTimeOrBuilder()
The timestamp when the price starts to be effective. This can be set as a future timestamp, and the price is only used for search after price_effective_time. If so, the original_price must be set and original_price is used before price_effective_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_effective_time = 5;
Type | Description |
TimestampOrBuilder |
getPriceExpireTime()
public Timestamp getPriceExpireTime()
The timestamp when the price stops to be effective. The price is used for search before price_expire_time. If this field is set, the original_price must be set and original_price is used after price_expire_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_expire_time = 6;
Type | Description |
Timestamp | The priceExpireTime. |
getPriceExpireTimeBuilder()
public Timestamp.Builder getPriceExpireTimeBuilder()
The timestamp when the price stops to be effective. The price is used for search before price_expire_time. If this field is set, the original_price must be set and original_price is used after price_expire_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_expire_time = 6;
Type | Description |
Builder |
getPriceExpireTimeOrBuilder()
public TimestampOrBuilder getPriceExpireTimeOrBuilder()
The timestamp when the price stops to be effective. The price is used for search before price_expire_time. If this field is set, the original_price must be set and original_price is used after price_expire_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_expire_time = 6;
Type | Description |
TimestampOrBuilder |
getPriceRange()
public PriceInfo.PriceRange getPriceRange()
Output only. The price range of all the child Product.Type.VARIANT Products grouped together on the Product.Type.PRIMARY Product. Only populated for Product.Type.PRIMARY Products. Note: This field is OUTPUT_ONLY for ProductService.GetProduct. Do not set this field in API requests.
.google.cloud.retail.v2alpha.PriceInfo.PriceRange price_range = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
PriceInfo.PriceRange | The priceRange. |
getPriceRangeBuilder()
public PriceInfo.PriceRange.Builder getPriceRangeBuilder()
Output only. The price range of all the child Product.Type.VARIANT Products grouped together on the Product.Type.PRIMARY Product. Only populated for Product.Type.PRIMARY Products. Note: This field is OUTPUT_ONLY for ProductService.GetProduct. Do not set this field in API requests.
.google.cloud.retail.v2alpha.PriceInfo.PriceRange price_range = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
PriceInfo.PriceRange.Builder |
getPriceRangeOrBuilder()
public PriceInfo.PriceRangeOrBuilder getPriceRangeOrBuilder()
Output only. The price range of all the child Product.Type.VARIANT Products grouped together on the Product.Type.PRIMARY Product. Only populated for Product.Type.PRIMARY Products. Note: This field is OUTPUT_ONLY for ProductService.GetProduct. Do not set this field in API requests.
.google.cloud.retail.v2alpha.PriceInfo.PriceRange price_range = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
PriceInfo.PriceRangeOrBuilder |
hasPriceEffectiveTime()
public boolean hasPriceEffectiveTime()
The timestamp when the price starts to be effective. This can be set as a future timestamp, and the price is only used for search after price_effective_time. If so, the original_price must be set and original_price is used before price_effective_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_effective_time = 5;
Type | Description |
boolean | Whether the priceEffectiveTime field is set. |
hasPriceExpireTime()
public boolean hasPriceExpireTime()
The timestamp when the price stops to be effective. The price is used for search before price_expire_time. If this field is set, the original_price must be set and original_price is used after price_expire_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_expire_time = 6;
Type | Description |
boolean | Whether the priceExpireTime field is set. |
hasPriceRange()
public boolean hasPriceRange()
Output only. The price range of all the child Product.Type.VARIANT Products grouped together on the Product.Type.PRIMARY Product. Only populated for Product.Type.PRIMARY Products. Note: This field is OUTPUT_ONLY for ProductService.GetProduct. Do not set this field in API requests.
.google.cloud.retail.v2alpha.PriceInfo.PriceRange price_range = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
boolean | Whether the priceRange field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Type | Description |
FieldAccessorTable |
isInitialized()
public final boolean isInitialized()
Type | Description |
boolean |
mergeFrom(PriceInfo other)
public PriceInfo.Builder mergeFrom(PriceInfo other)
Name | Description |
other | PriceInfo |
Type | Description |
PriceInfo.Builder |
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public PriceInfo.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Name | Description |
input | CodedInputStream |
extensionRegistry | ExtensionRegistryLite |
Type | Description |
PriceInfo.Builder |
Type | Description |
IOException |
mergeFrom(Message other)
public PriceInfo.Builder mergeFrom(Message other)
Name | Description |
other | Message |
Type | Description |
PriceInfo.Builder |
mergePriceEffectiveTime(Timestamp value)
public PriceInfo.Builder mergePriceEffectiveTime(Timestamp value)
The timestamp when the price starts to be effective. This can be set as a future timestamp, and the price is only used for search after price_effective_time. If so, the original_price must be set and original_price is used before price_effective_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_effective_time = 5;
Name | Description |
value | Timestamp |
Type | Description |
PriceInfo.Builder |
mergePriceExpireTime(Timestamp value)
public PriceInfo.Builder mergePriceExpireTime(Timestamp value)
The timestamp when the price stops to be effective. The price is used for search before price_expire_time. If this field is set, the original_price must be set and original_price is used after price_expire_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_expire_time = 6;
Name | Description |
value | Timestamp |
Type | Description |
PriceInfo.Builder |
mergePriceRange(PriceInfo.PriceRange value)
public PriceInfo.Builder mergePriceRange(PriceInfo.PriceRange value)
Output only. The price range of all the child Product.Type.VARIANT Products grouped together on the Product.Type.PRIMARY Product. Only populated for Product.Type.PRIMARY Products. Note: This field is OUTPUT_ONLY for ProductService.GetProduct. Do not set this field in API requests.
.google.cloud.retail.v2alpha.PriceInfo.PriceRange price_range = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | PriceInfo.PriceRange |
Type | Description |
PriceInfo.Builder |
mergeUnknownFields(UnknownFieldSet unknownFields)
public final PriceInfo.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Name | Description |
unknownFields | UnknownFieldSet |
Type | Description |
PriceInfo.Builder |
setCost(float value)
public PriceInfo.Builder setCost(float value)
The costs associated with the sale of a particular product. Used for gross profit reporting.
- Profit = price - cost Google Merchant Center property cost_of_goods_sold.
float cost = 4;
Name | Description |
value | float The cost to set. |
Type | Description |
PriceInfo.Builder | This builder for chaining. |
setCurrencyCode(String value)
public PriceInfo.Builder setCurrencyCode(String value)
The 3-letter currency code defined in ISO 4217. If this field is an unrecognizable currency code, an INVALID_ARGUMENT error is returned. The Product.Type.VARIANT Products with the same Product.primary_product_id must share the same currency_code. Otherwise, a FAILED_PRECONDITION error is returned.
string currency_code = 1;
Name | Description |
value | String The currencyCode to set. |
Type | Description |
PriceInfo.Builder | This builder for chaining. |
setCurrencyCodeBytes(ByteString value)
public PriceInfo.Builder setCurrencyCodeBytes(ByteString value)
The 3-letter currency code defined in ISO 4217. If this field is an unrecognizable currency code, an INVALID_ARGUMENT error is returned. The Product.Type.VARIANT Products with the same Product.primary_product_id must share the same currency_code. Otherwise, a FAILED_PRECONDITION error is returned.
string currency_code = 1;
Name | Description |
value | ByteString The bytes for currencyCode to set. |
Type | Description |
PriceInfo.Builder | This builder for chaining. |
setField(Descriptors.FieldDescriptor field, Object value)
public PriceInfo.Builder setField(Descriptors.FieldDescriptor field, Object value)
Name | Description |
field | FieldDescriptor |
value | Object |
Type | Description |
PriceInfo.Builder |
setOriginalPrice(float value)
public PriceInfo.Builder setOriginalPrice(float value)
Price of the product without any discount. If zero, by default set to be the price.
float original_price = 3;
Name | Description |
value | float The originalPrice to set. |
Type | Description |
PriceInfo.Builder | This builder for chaining. |
setPrice(float value)
public PriceInfo.Builder setPrice(float value)
Price of the product. Google Merchant Center property price. Schema.org property Offer.price.
float price = 2;
Name | Description |
value | float The price to set. |
Type | Description |
PriceInfo.Builder | This builder for chaining. |
setPriceEffectiveTime(Timestamp value)
public PriceInfo.Builder setPriceEffectiveTime(Timestamp value)
The timestamp when the price starts to be effective. This can be set as a future timestamp, and the price is only used for search after price_effective_time. If so, the original_price must be set and original_price is used before price_effective_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_effective_time = 5;
Name | Description |
value | Timestamp |
Type | Description |
PriceInfo.Builder |
setPriceEffectiveTime(Timestamp.Builder builderForValue)
public PriceInfo.Builder setPriceEffectiveTime(Timestamp.Builder builderForValue)
The timestamp when the price starts to be effective. This can be set as a future timestamp, and the price is only used for search after price_effective_time. If so, the original_price must be set and original_price is used before price_effective_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_effective_time = 5;
Name | Description |
builderForValue | Builder |
Type | Description |
PriceInfo.Builder |
setPriceExpireTime(Timestamp value)
public PriceInfo.Builder setPriceExpireTime(Timestamp value)
The timestamp when the price stops to be effective. The price is used for search before price_expire_time. If this field is set, the original_price must be set and original_price is used after price_expire_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_expire_time = 6;
Name | Description |
value | Timestamp |
Type | Description |
PriceInfo.Builder |
setPriceExpireTime(Timestamp.Builder builderForValue)
public PriceInfo.Builder setPriceExpireTime(Timestamp.Builder builderForValue)
The timestamp when the price stops to be effective. The price is used for search before price_expire_time. If this field is set, the original_price must be set and original_price is used after price_expire_time. Do not set if price is always effective because it will cause additional latency during search.
.google.protobuf.Timestamp price_expire_time = 6;
Name | Description |
builderForValue | Builder |
Type | Description |
PriceInfo.Builder |
setPriceRange(PriceInfo.PriceRange value)
public PriceInfo.Builder setPriceRange(PriceInfo.PriceRange value)
Output only. The price range of all the child Product.Type.VARIANT Products grouped together on the Product.Type.PRIMARY Product. Only populated for Product.Type.PRIMARY Products. Note: This field is OUTPUT_ONLY for ProductService.GetProduct. Do not set this field in API requests.
.google.cloud.retail.v2alpha.PriceInfo.PriceRange price_range = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | PriceInfo.PriceRange |
Type | Description |
PriceInfo.Builder |
setPriceRange(PriceInfo.PriceRange.Builder builderForValue)
public PriceInfo.Builder setPriceRange(PriceInfo.PriceRange.Builder builderForValue)
Output only. The price range of all the child Product.Type.VARIANT Products grouped together on the Product.Type.PRIMARY Product. Only populated for Product.Type.PRIMARY Products. Note: This field is OUTPUT_ONLY for ProductService.GetProduct. Do not set this field in API requests.
.google.cloud.retail.v2alpha.PriceInfo.PriceRange price_range = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
builderForValue | PriceInfo.PriceRange.Builder |
Type | Description |
PriceInfo.Builder |
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public PriceInfo.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Name | Description |
field | FieldDescriptor |
index | int |
value | Object |
Type | Description |
PriceInfo.Builder |
setUnknownFields(UnknownFieldSet unknownFields)
public final PriceInfo.Builder setUnknownFields(UnknownFieldSet unknownFields)
Name | Description |
unknownFields | UnknownFieldSet |
Type | Description |
PriceInfo.Builder |