Class PriceByResource.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<PriceByResource.Builder>
com.google.cloud.channel.v1.PriceByResource.Builder
All Implemented Interfaces:
PriceByResourceOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
PriceByResource

public static final class PriceByResource.Builder extends com.google.protobuf.GeneratedMessage.Builder<PriceByResource.Builder> implements PriceByResourceOrBuilder
 Represents price by resource type.
 
Protobuf type google.cloud.channel.v1.PriceByResource
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<PriceByResource.Builder>
    • clear

      public PriceByResource.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<PriceByResource.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<PriceByResource.Builder>
    • getDefaultInstanceForType

      public PriceByResource getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public PriceByResource build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public PriceByResource buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public PriceByResource.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<PriceByResource.Builder>
    • mergeFrom

      public PriceByResource.Builder mergeFrom(PriceByResource other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<PriceByResource.Builder>
    • mergeFrom

      public PriceByResource.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<PriceByResource.Builder>
      Throws:
      IOException
    • getResourceTypeValue

      public int getResourceTypeValue()
       Resource Type. Example: SEAT
       
      .google.cloud.channel.v1.ResourceType resource_type = 1;
      Specified by:
      getResourceTypeValue in interface PriceByResourceOrBuilder
      Returns:
      The enum numeric value on the wire for resourceType.
    • setResourceTypeValue

      public PriceByResource.Builder setResourceTypeValue(int value)
       Resource Type. Example: SEAT
       
      .google.cloud.channel.v1.ResourceType resource_type = 1;
      Parameters:
      value - The enum numeric value on the wire for resourceType to set.
      Returns:
      This builder for chaining.
    • getResourceType

      public ResourceType getResourceType()
       Resource Type. Example: SEAT
       
      .google.cloud.channel.v1.ResourceType resource_type = 1;
      Specified by:
      getResourceType in interface PriceByResourceOrBuilder
      Returns:
      The resourceType.
    • setResourceType

      public PriceByResource.Builder setResourceType(ResourceType value)
       Resource Type. Example: SEAT
       
      .google.cloud.channel.v1.ResourceType resource_type = 1;
      Parameters:
      value - The resourceType to set.
      Returns:
      This builder for chaining.
    • clearResourceType

      public PriceByResource.Builder clearResourceType()
       Resource Type. Example: SEAT
       
      .google.cloud.channel.v1.ResourceType resource_type = 1;
      Returns:
      This builder for chaining.
    • hasPrice

      public boolean hasPrice()
       Price of the Offer. Present if there are no price phases.
       
      .google.cloud.channel.v1.Price price = 2;
      Specified by:
      hasPrice in interface PriceByResourceOrBuilder
      Returns:
      Whether the price field is set.
    • getPrice

      public Price getPrice()
       Price of the Offer. Present if there are no price phases.
       
      .google.cloud.channel.v1.Price price = 2;
      Specified by:
      getPrice in interface PriceByResourceOrBuilder
      Returns:
      The price.
    • setPrice

      public PriceByResource.Builder setPrice(Price value)
       Price of the Offer. Present if there are no price phases.
       
      .google.cloud.channel.v1.Price price = 2;
    • setPrice

      public PriceByResource.Builder setPrice(Price.Builder builderForValue)
       Price of the Offer. Present if there are no price phases.
       
      .google.cloud.channel.v1.Price price = 2;
    • mergePrice

      public PriceByResource.Builder mergePrice(Price value)
       Price of the Offer. Present if there are no price phases.
       
      .google.cloud.channel.v1.Price price = 2;
    • clearPrice

      public PriceByResource.Builder clearPrice()
       Price of the Offer. Present if there are no price phases.
       
      .google.cloud.channel.v1.Price price = 2;
    • getPriceBuilder

      public Price.Builder getPriceBuilder()
       Price of the Offer. Present if there are no price phases.
       
      .google.cloud.channel.v1.Price price = 2;
    • getPriceOrBuilder

      public PriceOrBuilder getPriceOrBuilder()
       Price of the Offer. Present if there are no price phases.
       
      .google.cloud.channel.v1.Price price = 2;
      Specified by:
      getPriceOrBuilder in interface PriceByResourceOrBuilder
    • getPricePhasesList

      public List<PricePhase> getPricePhasesList()
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
      Specified by:
      getPricePhasesList in interface PriceByResourceOrBuilder
    • getPricePhasesCount

      public int getPricePhasesCount()
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
      Specified by:
      getPricePhasesCount in interface PriceByResourceOrBuilder
    • getPricePhases

      public PricePhase getPricePhases(int index)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
      Specified by:
      getPricePhases in interface PriceByResourceOrBuilder
    • setPricePhases

      public PriceByResource.Builder setPricePhases(int index, PricePhase value)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • setPricePhases

      public PriceByResource.Builder setPricePhases(int index, PricePhase.Builder builderForValue)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • addPricePhases

      public PriceByResource.Builder addPricePhases(PricePhase value)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • addPricePhases

      public PriceByResource.Builder addPricePhases(int index, PricePhase value)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • addPricePhases

      public PriceByResource.Builder addPricePhases(PricePhase.Builder builderForValue)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • addPricePhases

      public PriceByResource.Builder addPricePhases(int index, PricePhase.Builder builderForValue)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • addAllPricePhases

      public PriceByResource.Builder addAllPricePhases(Iterable<? extends PricePhase> values)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • clearPricePhases

      public PriceByResource.Builder clearPricePhases()
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • removePricePhases

      public PriceByResource.Builder removePricePhases(int index)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • getPricePhasesBuilder

      public PricePhase.Builder getPricePhasesBuilder(int index)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • getPricePhasesOrBuilder

      public PricePhaseOrBuilder getPricePhasesOrBuilder(int index)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
      Specified by:
      getPricePhasesOrBuilder in interface PriceByResourceOrBuilder
    • getPricePhasesOrBuilderList

      public List<? extends PricePhaseOrBuilder> getPricePhasesOrBuilderList()
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
      Specified by:
      getPricePhasesOrBuilderList in interface PriceByResourceOrBuilder
    • addPricePhasesBuilder

      public PricePhase.Builder addPricePhasesBuilder()
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • addPricePhasesBuilder

      public PricePhase.Builder addPricePhasesBuilder(int index)
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;
    • getPricePhasesBuilderList

      public List<PricePhase.Builder> getPricePhasesBuilderList()
       Specifies the price by time range.
       
      repeated .google.cloud.channel.v1.PricePhase price_phases = 3;