Send feedback
Class PriceTier.Builder (3.12.0)
Stay organized with collections
Save and categorize content based on your preferences.
Version 3.12.0 keyboard_arrow_down
public static final class PriceTier . Builder extends GeneratedMessageV3 . Builder<PriceTier . Builder > implements PriceTierOrBuilder
Defines price at resource tier level.
For example, an offer with following definition :
Tier 1: Provide 25% discount for all seats between 1 and 25.
Tier 2: Provide 10% discount for all seats between 26 and 100.
Tier 3: Provide flat 15% discount for all seats above 100.
Each of these tiers is represented as a PriceTier.
Protobuf type google.cloud.channel.v1.PriceTier
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors . Descriptor getDescriptor ()
Returns
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public PriceTier . Builder addRepeatedField ( Descriptors . FieldDescriptor field , Object value )
Parameters
Returns
Overrides
build()
Returns
buildPartial()
public PriceTier buildPartial ()
Returns
clear()
public PriceTier . Builder clear ()
Returns
Overrides
clearField(Descriptors.FieldDescriptor field)
public PriceTier . Builder clearField ( Descriptors . FieldDescriptor field )
Parameter
Returns
Overrides
clearFirstResource()
public PriceTier . Builder clearFirstResource ()
First resource for which the tier price applies.
int32 first_resource = 1;
Returns
clearLastResource()
public PriceTier . Builder clearLastResource ()
Last resource for which the tier price applies.
int32 last_resource = 2;
Returns
clearOneof(Descriptors.OneofDescriptor oneof)
public PriceTier . Builder clearOneof ( Descriptors . OneofDescriptor oneof )
Parameter
Returns
Overrides
clearPrice()
public PriceTier . Builder clearPrice ()
Price of the tier.
.google.cloud.channel.v1.Price price = 3;
Returns
clone()
public PriceTier . Builder clone ()
Returns
Overrides
getDefaultInstanceForType()
public PriceTier getDefaultInstanceForType ()
Returns
getDescriptorForType()
public Descriptors . Descriptor getDescriptorForType ()
Returns
Overrides
getFirstResource()
public int getFirstResource ()
First resource for which the tier price applies.
int32 first_resource = 1;
Returns
Type Description int The firstResource.
getLastResource()
public int getLastResource ()
Last resource for which the tier price applies.
int32 last_resource = 2;
Returns
Type Description int The lastResource.
getPrice()
Price of the tier.
.google.cloud.channel.v1.Price price = 3;
Returns
Type Description Price The price.
getPriceBuilder()
public Price . Builder getPriceBuilder ()
Price of the tier.
.google.cloud.channel.v1.Price price = 3;
Returns
getPriceOrBuilder()
public PriceOrBuilder getPriceOrBuilder ()
Price of the tier.
.google.cloud.channel.v1.Price price = 3;
Returns
hasPrice()
public boolean hasPrice ()
Price of the tier.
.google.cloud.channel.v1.Price price = 3;
Returns
Type Description boolean Whether the price field is set.
internalGetFieldAccessorTable()
protected GeneratedMessageV3 . FieldAccessorTable internalGetFieldAccessorTable ()
Returns
Overrides
isInitialized()
public final boolean isInitialized ()
Returns
Overrides
mergeFrom(PriceTier other)
public PriceTier . Builder mergeFrom ( PriceTier other )
Parameter
Returns
public PriceTier . Builder mergeFrom ( CodedInputStream input , ExtensionRegistryLite extensionRegistry )
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public PriceTier . Builder mergeFrom ( Message other )
Parameter
Returns
Overrides
mergePrice(Price value)
public PriceTier . Builder mergePrice ( Price value )
Price of the tier.
.google.cloud.channel.v1.Price price = 3;
Parameter
Name Description value Price
Returns
mergeUnknownFields(UnknownFieldSet unknownFields)
public final PriceTier . Builder mergeUnknownFields ( UnknownFieldSet unknownFields )
Parameter
Returns
Overrides
setField(Descriptors.FieldDescriptor field, Object value)
public PriceTier . Builder setField ( Descriptors . FieldDescriptor field , Object value )
Parameters
Returns
Overrides
setFirstResource(int value)
public PriceTier . Builder setFirstResource ( int value )
First resource for which the tier price applies.
int32 first_resource = 1;
Parameter
Name Description value int
The firstResource to set.
Returns
setLastResource(int value)
public PriceTier . Builder setLastResource ( int value )
Last resource for which the tier price applies.
int32 last_resource = 2;
Parameter
Name Description value int
The lastResource to set.
Returns
setPrice(Price value)
public PriceTier . Builder setPrice ( Price value )
Price of the tier.
.google.cloud.channel.v1.Price price = 3;
Parameter
Name Description value Price
Returns
setPrice(Price.Builder builderForValue)
public PriceTier . Builder setPrice ( Price . Builder builderForValue )
Price of the tier.
.google.cloud.channel.v1.Price price = 3;
Parameter
Returns
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public PriceTier . Builder setRepeatedField ( Descriptors . FieldDescriptor field , int index , Object value )
Parameters
Returns
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final PriceTier . Builder setUnknownFields ( UnknownFieldSet unknownFields )
Parameter
Returns
Overrides
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-01-27 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-01-27 UTC."],[],[]]