Class BudgetAmount.Builder

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

public static final class BudgetAmount.Builder extends com.google.protobuf.GeneratedMessage.Builder<BudgetAmount.Builder> implements BudgetAmountOrBuilder
 The budgeted amount for each usage period.
 
Protobuf type google.cloud.billing.budgets.v1.BudgetAmount
  • 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<BudgetAmount.Builder>
    • clear

      public BudgetAmount.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<BudgetAmount.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<BudgetAmount.Builder>
    • getDefaultInstanceForType

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

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

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

      public BudgetAmount.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<BudgetAmount.Builder>
    • mergeFrom

      public BudgetAmount.Builder mergeFrom(BudgetAmount other)
    • isInitialized

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

      public BudgetAmount.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<BudgetAmount.Builder>
      Throws:
      IOException
    • getBudgetAmountCase

      public BudgetAmount.BudgetAmountCase getBudgetAmountCase()
      Specified by:
      getBudgetAmountCase in interface BudgetAmountOrBuilder
    • clearBudgetAmount

      public BudgetAmount.Builder clearBudgetAmount()
    • hasSpecifiedAmount

      public boolean hasSpecifiedAmount()
       A specified amount to use as the budget.
       `currency_code` is optional. If specified when creating a budget, it must
       match the currency of the billing account. If specified when updating a
       budget, it must match the currency_code of the existing budget.
       The `currency_code` is provided on output.
       
      .google.type.Money specified_amount = 1;
      Specified by:
      hasSpecifiedAmount in interface BudgetAmountOrBuilder
      Returns:
      Whether the specifiedAmount field is set.
    • getSpecifiedAmount

      public Money getSpecifiedAmount()
       A specified amount to use as the budget.
       `currency_code` is optional. If specified when creating a budget, it must
       match the currency of the billing account. If specified when updating a
       budget, it must match the currency_code of the existing budget.
       The `currency_code` is provided on output.
       
      .google.type.Money specified_amount = 1;
      Specified by:
      getSpecifiedAmount in interface BudgetAmountOrBuilder
      Returns:
      The specifiedAmount.
    • setSpecifiedAmount

      public BudgetAmount.Builder setSpecifiedAmount(Money value)
       A specified amount to use as the budget.
       `currency_code` is optional. If specified when creating a budget, it must
       match the currency of the billing account. If specified when updating a
       budget, it must match the currency_code of the existing budget.
       The `currency_code` is provided on output.
       
      .google.type.Money specified_amount = 1;
    • setSpecifiedAmount

      public BudgetAmount.Builder setSpecifiedAmount(Money.Builder builderForValue)
       A specified amount to use as the budget.
       `currency_code` is optional. If specified when creating a budget, it must
       match the currency of the billing account. If specified when updating a
       budget, it must match the currency_code of the existing budget.
       The `currency_code` is provided on output.
       
      .google.type.Money specified_amount = 1;
    • mergeSpecifiedAmount

      public BudgetAmount.Builder mergeSpecifiedAmount(Money value)
       A specified amount to use as the budget.
       `currency_code` is optional. If specified when creating a budget, it must
       match the currency of the billing account. If specified when updating a
       budget, it must match the currency_code of the existing budget.
       The `currency_code` is provided on output.
       
      .google.type.Money specified_amount = 1;
    • clearSpecifiedAmount

      public BudgetAmount.Builder clearSpecifiedAmount()
       A specified amount to use as the budget.
       `currency_code` is optional. If specified when creating a budget, it must
       match the currency of the billing account. If specified when updating a
       budget, it must match the currency_code of the existing budget.
       The `currency_code` is provided on output.
       
      .google.type.Money specified_amount = 1;
    • getSpecifiedAmountBuilder

      public Money.Builder getSpecifiedAmountBuilder()
       A specified amount to use as the budget.
       `currency_code` is optional. If specified when creating a budget, it must
       match the currency of the billing account. If specified when updating a
       budget, it must match the currency_code of the existing budget.
       The `currency_code` is provided on output.
       
      .google.type.Money specified_amount = 1;
    • getSpecifiedAmountOrBuilder

      public MoneyOrBuilder getSpecifiedAmountOrBuilder()
       A specified amount to use as the budget.
       `currency_code` is optional. If specified when creating a budget, it must
       match the currency of the billing account. If specified when updating a
       budget, it must match the currency_code of the existing budget.
       The `currency_code` is provided on output.
       
      .google.type.Money specified_amount = 1;
      Specified by:
      getSpecifiedAmountOrBuilder in interface BudgetAmountOrBuilder
    • hasLastPeriodAmount

      public boolean hasLastPeriodAmount()
       Use the last period's actual spend as the budget for the present period.
       LastPeriodAmount can only be set when the budget's time period is a
       [Filter.calendar_period][google.cloud.billing.budgets.v1.Filter.calendar_period].
       It cannot be set in combination with
       [Filter.custom_period][google.cloud.billing.budgets.v1.Filter.custom_period].
       
      .google.cloud.billing.budgets.v1.LastPeriodAmount last_period_amount = 2;
      Specified by:
      hasLastPeriodAmount in interface BudgetAmountOrBuilder
      Returns:
      Whether the lastPeriodAmount field is set.
    • getLastPeriodAmount

      public LastPeriodAmount getLastPeriodAmount()
       Use the last period's actual spend as the budget for the present period.
       LastPeriodAmount can only be set when the budget's time period is a
       [Filter.calendar_period][google.cloud.billing.budgets.v1.Filter.calendar_period].
       It cannot be set in combination with
       [Filter.custom_period][google.cloud.billing.budgets.v1.Filter.custom_period].
       
      .google.cloud.billing.budgets.v1.LastPeriodAmount last_period_amount = 2;
      Specified by:
      getLastPeriodAmount in interface BudgetAmountOrBuilder
      Returns:
      The lastPeriodAmount.
    • setLastPeriodAmount

      public BudgetAmount.Builder setLastPeriodAmount(LastPeriodAmount value)
       Use the last period's actual spend as the budget for the present period.
       LastPeriodAmount can only be set when the budget's time period is a
       [Filter.calendar_period][google.cloud.billing.budgets.v1.Filter.calendar_period].
       It cannot be set in combination with
       [Filter.custom_period][google.cloud.billing.budgets.v1.Filter.custom_period].
       
      .google.cloud.billing.budgets.v1.LastPeriodAmount last_period_amount = 2;
    • setLastPeriodAmount

      public BudgetAmount.Builder setLastPeriodAmount(LastPeriodAmount.Builder builderForValue)
       Use the last period's actual spend as the budget for the present period.
       LastPeriodAmount can only be set when the budget's time period is a
       [Filter.calendar_period][google.cloud.billing.budgets.v1.Filter.calendar_period].
       It cannot be set in combination with
       [Filter.custom_period][google.cloud.billing.budgets.v1.Filter.custom_period].
       
      .google.cloud.billing.budgets.v1.LastPeriodAmount last_period_amount = 2;
    • mergeLastPeriodAmount

      public BudgetAmount.Builder mergeLastPeriodAmount(LastPeriodAmount value)
       Use the last period's actual spend as the budget for the present period.
       LastPeriodAmount can only be set when the budget's time period is a
       [Filter.calendar_period][google.cloud.billing.budgets.v1.Filter.calendar_period].
       It cannot be set in combination with
       [Filter.custom_period][google.cloud.billing.budgets.v1.Filter.custom_period].
       
      .google.cloud.billing.budgets.v1.LastPeriodAmount last_period_amount = 2;
    • clearLastPeriodAmount

      public BudgetAmount.Builder clearLastPeriodAmount()
       Use the last period's actual spend as the budget for the present period.
       LastPeriodAmount can only be set when the budget's time period is a
       [Filter.calendar_period][google.cloud.billing.budgets.v1.Filter.calendar_period].
       It cannot be set in combination with
       [Filter.custom_period][google.cloud.billing.budgets.v1.Filter.custom_period].
       
      .google.cloud.billing.budgets.v1.LastPeriodAmount last_period_amount = 2;
    • getLastPeriodAmountBuilder

      public LastPeriodAmount.Builder getLastPeriodAmountBuilder()
       Use the last period's actual spend as the budget for the present period.
       LastPeriodAmount can only be set when the budget's time period is a
       [Filter.calendar_period][google.cloud.billing.budgets.v1.Filter.calendar_period].
       It cannot be set in combination with
       [Filter.custom_period][google.cloud.billing.budgets.v1.Filter.custom_period].
       
      .google.cloud.billing.budgets.v1.LastPeriodAmount last_period_amount = 2;
    • getLastPeriodAmountOrBuilder

      public LastPeriodAmountOrBuilder getLastPeriodAmountOrBuilder()
       Use the last period's actual spend as the budget for the present period.
       LastPeriodAmount can only be set when the budget's time period is a
       [Filter.calendar_period][google.cloud.billing.budgets.v1.Filter.calendar_period].
       It cannot be set in combination with
       [Filter.custom_period][google.cloud.billing.budgets.v1.Filter.custom_period].
       
      .google.cloud.billing.budgets.v1.LastPeriodAmount last_period_amount = 2;
      Specified by:
      getLastPeriodAmountOrBuilder in interface BudgetAmountOrBuilder