diff --git a/google-cloud-billingbudgets/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetServiceClient.java b/google-cloud-billingbudgets/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetServiceClient.java index 21e46018..9b09d6da 100644 --- a/google-cloud-billingbudgets/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetServiceClient.java +++ b/google-cloud-billingbudgets/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetServiceClient.java @@ -215,7 +215,7 @@ public final UnaryCallable createBudgetCallable() { /** * Updates a budget and returns the updated budget. * - *

WARNING: There are some fields exposed on the Google Cloud Console that aren’t available on + *

WARNING: There are some fields exposed on the Google Cloud Console that aren't available on * this API. Budget fields that are not exposed in this API will not be changed by this method. * *

Sample code: @@ -241,7 +241,7 @@ public final Budget updateBudget(UpdateBudgetRequest request) { /** * Updates a budget and returns the updated budget. * - *

WARNING: There are some fields exposed on the Google Cloud Console that aren’t available on + *

WARNING: There are some fields exposed on the Google Cloud Console that aren't available on * this API. Budget fields that are not exposed in this API will not be changed by this method. * *

Sample code: @@ -266,7 +266,7 @@ public final UnaryCallable updateBudgetCallable() { /** * Returns a budget. * - *

WARNING: There are some fields exposed on the Google Cloud Console that aren’t available on + *

WARNING: There are some fields exposed on the Google Cloud Console that aren't available on * this API. When reading from the API, you will not see these fields in the return value, though * they may have been set in the Cloud Console. * @@ -293,7 +293,7 @@ public final Budget getBudget(GetBudgetRequest request) { /** * Returns a budget. * - *

WARNING: There are some fields exposed on the Google Cloud Console that aren’t available on + *

WARNING: There are some fields exposed on the Google Cloud Console that aren't available on * this API. When reading from the API, you will not see these fields in the return value, though * they may have been set in the Cloud Console. * @@ -319,7 +319,7 @@ public final UnaryCallable getBudgetCallable() { /** * Returns a list of budgets for a billing account. * - *

WARNING: There are some fields exposed on the Google Cloud Console that aren’t available on + *

WARNING: There are some fields exposed on the Google Cloud Console that aren't available on * this API. When reading from the API, you will not see these fields in the return value, though * they may have been set in the Cloud Console. * @@ -348,7 +348,7 @@ public final ListBudgetsPagedResponse listBudgets(ListBudgetsRequest request) { /** * Returns a list of budgets for a billing account. * - *

WARNING: There are some fields exposed on the Google Cloud Console that aren’t available on + *

WARNING: There are some fields exposed on the Google Cloud Console that aren't available on * this API. When reading from the API, you will not see these fields in the return value, though * they may have been set in the Cloud Console. * @@ -377,7 +377,7 @@ public final ListBudgetsPagedResponse listBudgets(ListBudgetsRequest request) { /** * Returns a list of budgets for a billing account. * - *

WARNING: There are some fields exposed on the Google Cloud Console that aren’t available on + *

WARNING: There are some fields exposed on the Google Cloud Console that aren't available on * this API. When reading from the API, you will not see these fields in the return value, though * they may have been set in the Cloud Console. * diff --git a/grpc-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetServiceGrpc.java b/grpc-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetServiceGrpc.java index 4c597d55..6abec03a 100644 --- a/grpc-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetServiceGrpc.java +++ b/grpc-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetServiceGrpc.java @@ -339,7 +339,7 @@ public void createBudget( *

      * Updates a budget and returns the updated budget.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. Budget fields that are not exposed in
+     * aren't available on this API. Budget fields that are not exposed in
      * this API will not be changed by this method.
      * 
*/ @@ -356,7 +356,7 @@ public void updateBudget( *
      * Returns a budget.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. When reading from the API, you will not
+     * aren't available on this API. When reading from the API, you will not
      * see these fields in the return value, though they may have been set
      * in the Cloud Console.
      * 
@@ -374,7 +374,7 @@ public void getBudget( *
      * Returns a list of budgets for a billing account.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. When reading from the API, you will not
+     * aren't available on this API. When reading from the API, you will not
      * see these fields in the return value, though they may have been set
      * in the Cloud Console.
      * 
@@ -483,7 +483,7 @@ public void createBudget( *
      * Updates a budget and returns the updated budget.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. Budget fields that are not exposed in
+     * aren't available on this API. Budget fields that are not exposed in
      * this API will not be changed by this method.
      * 
*/ @@ -503,7 +503,7 @@ public void updateBudget( *
      * Returns a budget.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. When reading from the API, you will not
+     * aren't available on this API. When reading from the API, you will not
      * see these fields in the return value, though they may have been set
      * in the Cloud Console.
      * 
@@ -522,7 +522,7 @@ public void getBudget( *
      * Returns a list of budgets for a billing account.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. When reading from the API, you will not
+     * aren't available on this API. When reading from the API, you will not
      * see these fields in the return value, though they may have been set
      * in the Cloud Console.
      * 
@@ -594,7 +594,7 @@ public com.google.cloud.billing.budgets.v1beta1.Budget createBudget( *
      * Updates a budget and returns the updated budget.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. Budget fields that are not exposed in
+     * aren't available on this API. Budget fields that are not exposed in
      * this API will not be changed by this method.
      * 
*/ @@ -609,7 +609,7 @@ public com.google.cloud.billing.budgets.v1beta1.Budget updateBudget( *
      * Returns a budget.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. When reading from the API, you will not
+     * aren't available on this API. When reading from the API, you will not
      * see these fields in the return value, though they may have been set
      * in the Cloud Console.
      * 
@@ -625,7 +625,7 @@ public com.google.cloud.billing.budgets.v1beta1.Budget getBudget( *
      * Returns a list of budgets for a billing account.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. When reading from the API, you will not
+     * aren't available on this API. When reading from the API, you will not
      * see these fields in the return value, though they may have been set
      * in the Cloud Console.
      * 
@@ -690,7 +690,7 @@ protected BudgetServiceFutureStub build( *
      * Updates a budget and returns the updated budget.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. Budget fields that are not exposed in
+     * aren't available on this API. Budget fields that are not exposed in
      * this API will not be changed by this method.
      * 
*/ @@ -707,7 +707,7 @@ protected BudgetServiceFutureStub build( *
      * Returns a budget.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. When reading from the API, you will not
+     * aren't available on this API. When reading from the API, you will not
      * see these fields in the return value, though they may have been set
      * in the Cloud Console.
      * 
@@ -724,7 +724,7 @@ protected BudgetServiceFutureStub build( *
      * Returns a list of budgets for a billing account.
      * WARNING: There are some fields exposed on the Google Cloud Console that
-     * aren’t available on this API. When reading from the API, you will not
+     * aren't available on this API. When reading from the API, you will not
      * see these fields in the return value, though they may have been set
      * in the Cloud Console.
      * 
diff --git a/proto-google-cloud-billingbudgets-v1beta1/clirr-ignored-differences.xml b/proto-google-cloud-billingbudgets-v1beta1/clirr-ignored-differences.xml new file mode 100644 index 00000000..f5fd1ba3 --- /dev/null +++ b/proto-google-cloud-billingbudgets-v1beta1/clirr-ignored-differences.xml @@ -0,0 +1,19 @@ + + + + + 7012 + com/google/cloud/billing/budgets/v1beta1/*OrBuilder + * get*(*) + + + 7012 + com/google/cloud/billing/budgets/v1beta1/*OrBuilder + boolean contains*(*) + + + 7012 + com/google/cloud/billing/budgets/v1beta1/*OrBuilder + boolean has*(*) + + diff --git a/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetModel.java b/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetModel.java index b47653d5..09e8e5cc 100644 --- a/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetModel.java +++ b/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/BudgetModel.java @@ -51,6 +51,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_billing_budgets_v1beta1_Filter_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_billing_budgets_v1beta1_Filter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_billing_budgets_v1beta1_Filter_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_billing_budgets_v1beta1_Filter_LabelsEntry_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -63,42 +67,47 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "\n7google/cloud/billing/budgets/v1beta1/b" + "udget_model.proto\022$google.cloud.billing." + "budgets.v1beta1\032\037google/api/field_behavi" - + "or.proto\032\031google/api/resource.proto\032\027goo" - + "gle/type/money.proto\"\336\003\n\006Budget\022\021\n\004name\030" - + "\001 \001(\tB\003\340A\003\022\024\n\014display_name\030\002 \001(\t\022H\n\rbudg" - + "et_filter\030\003 \001(\0132,.google.cloud.billing.b" - + "udgets.v1beta1.FilterB\003\340A\001\022G\n\006amount\030\004 \001" - + "(\01322.google.cloud.billing.budgets.v1beta" - + "1.BudgetAmountB\003\340A\002\022Q\n\017threshold_rules\030\005" - + " \003(\01323.google.cloud.billing.budgets.v1be" - + "ta1.ThresholdRuleB\003\340A\001\022S\n\020all_updates_ru" - + "le\030\006 \001(\01324.google.cloud.billing.budgets." - + "v1beta1.AllUpdatesRuleB\003\340A\001\022\021\n\004etag\030\007 \001(" - + "\tB\003\340A\001:]\352AZ\n$billingbudgets.googleapis.c" - + "om/Budget\0222billingAccounts/{billing_acco" - + "unt}/budgets/{budget}\"\245\001\n\014BudgetAmount\022." - + "\n\020specified_amount\030\001 \001(\0132\022.google.type.M" - + "oneyH\000\022T\n\022last_period_amount\030\002 \001(\01326.goo" - + "gle.cloud.billing.budgets.v1beta1.LastPe" - + "riodAmountH\000B\017\n\rbudget_amount\"\022\n\020LastPer" - + "iodAmount\"\315\001\n\rThresholdRule\022\036\n\021threshold" - + "_percent\030\001 \001(\001B\003\340A\002\022S\n\013spend_basis\030\002 \001(\016" - + "29.google.cloud.billing.budgets.v1beta1." - + "ThresholdRule.BasisB\003\340A\001\"G\n\005Basis\022\025\n\021BAS" - + "IS_UNSPECIFIED\020\000\022\021\n\rCURRENT_SPEND\020\001\022\024\n\020F" - + "ORECASTED_SPEND\020\002\"H\n\016AllUpdatesRule\022\031\n\014p" - + "ubsub_topic\030\001 \001(\tB\003\340A\002\022\033\n\016schema_version" - + "\030\002 \001(\tB\003\340A\002\"\220\002\n\006Filter\022\025\n\010projects\030\001 \003(\t" - + "B\003\340A\001\022f\n\026credit_types_treatment\030\004 \001(\0162A." - + "google.cloud.billing.budgets.v1beta1.Fil" - + "ter.CreditTypesTreatmentB\003\340A\001\022\025\n\010service" - + "s\030\003 \003(\tB\003\340A\001\"p\n\024CreditTypesTreatment\022&\n\"" - + "CREDIT_TYPES_TREATMENT_UNSPECIFIED\020\000\022\027\n\023" - + "INCLUDE_ALL_CREDITS\020\001\022\027\n\023EXCLUDE_ALL_CRE" - + "DITS\020\002By\n(com.google.cloud.billing.budge" - + "ts.v1beta1P\001ZKgoogle.golang.org/genproto" - + "/googleapis/cloud/billing/budgets/v1beta" - + "1;budgetsb\006proto3" + + "or.proto\032\031google/api/resource.proto\032\034goo" + + "gle/protobuf/struct.proto\032\027google/type/m" + + "oney.proto\"\336\003\n\006Budget\022\021\n\004name\030\001 \001(\tB\003\340A\003" + + "\022\024\n\014display_name\030\002 \001(\t\022H\n\rbudget_filter\030" + + "\003 \001(\0132,.google.cloud.billing.budgets.v1b" + + "eta1.FilterB\003\340A\001\022G\n\006amount\030\004 \001(\01322.googl" + + "e.cloud.billing.budgets.v1beta1.BudgetAm" + + "ountB\003\340A\002\022Q\n\017threshold_rules\030\005 \003(\01323.goo" + + "gle.cloud.billing.budgets.v1beta1.Thresh" + + "oldRuleB\003\340A\001\022S\n\020all_updates_rule\030\006 \001(\01324" + + ".google.cloud.billing.budgets.v1beta1.Al" + + "lUpdatesRuleB\003\340A\001\022\021\n\004etag\030\007 \001(\tB\003\340A\001:]\352A" + + "Z\n$billingbudgets.googleapis.com/Budget\022" + + "2billingAccounts/{billing_account}/budge" + + "ts/{budget}\"\245\001\n\014BudgetAmount\022.\n\020specifie" + + "d_amount\030\001 \001(\0132\022.google.type.MoneyH\000\022T\n\022" + + "last_period_amount\030\002 \001(\01326.google.cloud." + + "billing.budgets.v1beta1.LastPeriodAmount" + + "H\000B\017\n\rbudget_amount\"\022\n\020LastPeriodAmount\"" + + "\315\001\n\rThresholdRule\022\036\n\021threshold_percent\030\001" + + " \001(\001B\003\340A\002\022S\n\013spend_basis\030\002 \001(\01629.google." + + "cloud.billing.budgets.v1beta1.ThresholdR" + + "ule.BasisB\003\340A\001\"G\n\005Basis\022\025\n\021BASIS_UNSPECI" + + "FIED\020\000\022\021\n\rCURRENT_SPEND\020\001\022\024\n\020FORECASTED_" + + "SPEND\020\002\"H\n\016AllUpdatesRule\022\031\n\014pubsub_topi" + + "c\030\001 \001(\tB\003\340A\002\022\033\n\016schema_version\030\002 \001(\tB\003\340A" + + "\002\"\304\003\n\006Filter\022\025\n\010projects\030\001 \003(\tB\003\340A\001\022f\n\026c" + + "redit_types_treatment\030\004 \001(\0162A.google.clo" + + "ud.billing.budgets.v1beta1.Filter.Credit" + + "TypesTreatmentB\003\340A\001\022\025\n\010services\030\003 \003(\tB\003\340" + + "A\001\022\030\n\013subaccounts\030\005 \003(\tB\003\340A\001\022M\n\006labels\030\006" + + " \003(\01328.google.cloud.billing.budgets.v1be" + + "ta1.Filter.LabelsEntryB\003\340A\001\032I\n\013LabelsEnt" + + "ry\022\013\n\003key\030\001 \001(\t\022)\n\005value\030\002 \001(\0132\032.google." + + "protobuf.ListValue:\0028\001\"p\n\024CreditTypesTre" + + "atment\022&\n\"CREDIT_TYPES_TREATMENT_UNSPECI" + + "FIED\020\000\022\027\n\023INCLUDE_ALL_CREDITS\020\001\022\027\n\023EXCLU" + + "DE_ALL_CREDITS\020\002By\n(com.google.cloud.bil" + + "ling.budgets.v1beta1P\001ZKgoogle.golang.or" + + "g/genproto/googleapis/cloud/billing/budg" + + "ets/v1beta1;budgetsb\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -106,6 +115,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.Descriptors.FileDescriptor[] { com.google.api.FieldBehaviorProto.getDescriptor(), com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.StructProto.getDescriptor(), com.google.type.MoneyProto.getDescriptor(), }); internal_static_google_cloud_billing_budgets_v1beta1_Budget_descriptor = @@ -158,7 +168,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_billing_budgets_v1beta1_Filter_descriptor, new java.lang.String[] { - "Projects", "CreditTypesTreatment", "Services", + "Projects", "CreditTypesTreatment", "Services", "Subaccounts", "Labels", + }); + internal_static_google_cloud_billing_budgets_v1beta1_Filter_LabelsEntry_descriptor = + internal_static_google_cloud_billing_budgets_v1beta1_Filter_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_billing_budgets_v1beta1_Filter_LabelsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_billing_budgets_v1beta1_Filter_LabelsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", }); com.google.protobuf.ExtensionRegistry registry = com.google.protobuf.ExtensionRegistry.newInstance(); @@ -168,6 +188,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { descriptor, registry); com.google.api.FieldBehaviorProto.getDescriptor(); com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.StructProto.getDescriptor(); com.google.type.MoneyProto.getDescriptor(); } diff --git a/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/Filter.java b/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/Filter.java index c79b7a0b..9cee936f 100644 --- a/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/Filter.java +++ b/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/Filter.java @@ -41,6 +41,7 @@ private Filter() { projects_ = com.google.protobuf.LazyStringArrayList.EMPTY; creditTypesTreatment_ = 0; services_ = com.google.protobuf.LazyStringArrayList.EMPTY; + subaccounts_ = com.google.protobuf.LazyStringArrayList.EMPTY; } @java.lang.Override @@ -100,6 +101,31 @@ private Filter( creditTypesTreatment_ = rawValue; break; } + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000004) != 0)) { + subaccounts_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000004; + } + subaccounts_.add(s); + break; + } + case 50: + { + if (!((mutable_bitField0_ & 0x00000008) != 0)) { + labels_ = + com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + mutable_bitField0_ |= 0x00000008; + } + com.google.protobuf.MapEntry + labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + labels_.getMutableMap().put(labels__.getKey(), labels__.getValue()); + break; + } default: { if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { @@ -120,6 +146,9 @@ private Filter( if (((mutable_bitField0_ & 0x00000002) != 0)) { services_ = services_.getUnmodifiableView(); } + if (((mutable_bitField0_ & 0x00000004) != 0)) { + subaccounts_ = subaccounts_.getUnmodifiableView(); + } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } @@ -130,6 +159,17 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { .internal_static_google_cloud_billing_budgets_v1beta1_Filter_descriptor; } + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 6: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { @@ -485,6 +525,202 @@ public com.google.protobuf.ByteString getServicesBytes(int index) { return services_.getByteString(index); } + public static final int SUBACCOUNTS_FIELD_NUMBER = 5; + private com.google.protobuf.LazyStringList subaccounts_; + /** + * + * + *
+   * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+   * that usage from only this set of subaccounts should be included in the
+   * budget. If a subaccount is set to the name of the master account, usage
+   * from the master account will be included. If omitted, the report will
+   * include usage from the master account and all subaccounts, if they exist.
+   * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return A list containing the subaccounts. + */ + public com.google.protobuf.ProtocolStringList getSubaccountsList() { + return subaccounts_; + } + /** + * + * + *
+   * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+   * that usage from only this set of subaccounts should be included in the
+   * budget. If a subaccount is set to the name of the master account, usage
+   * from the master account will be included. If omitted, the report will
+   * include usage from the master account and all subaccounts, if they exist.
+   * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The count of subaccounts. + */ + public int getSubaccountsCount() { + return subaccounts_.size(); + } + /** + * + * + *
+   * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+   * that usage from only this set of subaccounts should be included in the
+   * budget. If a subaccount is set to the name of the master account, usage
+   * from the master account will be included. If omitted, the report will
+   * include usage from the master account and all subaccounts, if they exist.
+   * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the element to return. + * @return The subaccounts at the given index. + */ + public java.lang.String getSubaccounts(int index) { + return subaccounts_.get(index); + } + /** + * + * + *
+   * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+   * that usage from only this set of subaccounts should be included in the
+   * budget. If a subaccount is set to the name of the master account, usage
+   * from the master account will be included. If omitted, the report will
+   * include usage from the master account and all subaccounts, if they exist.
+   * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the value to return. + * @return The bytes of the subaccounts at the given index. + */ + public com.google.protobuf.ByteString getSubaccountsBytes(int index) { + return subaccounts_.getByteString(index); + } + + public static final int LABELS_FIELD_NUMBER = 6; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry + defaultEntry = + com.google.protobuf.MapEntry + .newDefaultInstance( + com.google.cloud.billing.budgets.v1beta1.BudgetModel + .internal_static_google_cloud_billing_budgets_v1beta1_Filter_LabelsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.MESSAGE, + com.google.protobuf.ListValue.getDefaultInstance()); + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField + internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+   * Optional. A single label and value pair specifying that usage from only this set of
+   * labeled resources should be included in the budget. Multiple entries or
+   * multiple values per entry are not allowed. If omitted, the report will
+   * include all labeled and unlabeled usage.
+   * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+   * Optional. A single label and value pair specifying that usage from only this set of
+   * labeled resources should be included in the budget. Multiple entries or
+   * multiple values per entry are not allowed. If omitted, the report will
+   * include all labeled and unlabeled usage.
+   * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+   * Optional. A single label and value pair specifying that usage from only this set of
+   * labeled resources should be included in the budget. Multiple entries or
+   * multiple values per entry are not allowed. If omitted, the report will
+   * include all labeled and unlabeled usage.
+   * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.ListValue getLabelsOrDefault( + java.lang.String key, com.google.protobuf.ListValue defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = + internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+   * Optional. A single label and value pair specifying that usage from only this set of
+   * labeled resources should be included in the budget. Multiple entries or
+   * multiple values per entry are not allowed. If omitted, the report will
+   * include all labeled and unlabeled usage.
+   * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.ListValue getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = + internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -511,6 +747,11 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io .getNumber()) { output.writeEnum(4, creditTypesTreatment_); } + for (int i = 0; i < subaccounts_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, subaccounts_.getRaw(i)); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 6); unknownFields.writeTo(output); } @@ -542,6 +783,24 @@ public int getSerializedSize() { .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, creditTypesTreatment_); } + { + int dataSize = 0; + for (int i = 0; i < subaccounts_.size(); i++) { + dataSize += computeStringSizeNoTag(subaccounts_.getRaw(i)); + } + size += dataSize; + size += 1 * getSubaccountsList().size(); + } + for (java.util.Map.Entry entry : + internalGetLabels().getMap().entrySet()) { + com.google.protobuf.MapEntry labels__ = + LabelsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, labels__); + } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; @@ -561,6 +820,8 @@ public boolean equals(final java.lang.Object obj) { if (!getProjectsList().equals(other.getProjectsList())) return false; if (creditTypesTreatment_ != other.creditTypesTreatment_) return false; if (!getServicesList().equals(other.getServicesList())) return false; + if (!getSubaccountsList().equals(other.getSubaccountsList())) return false; + if (!internalGetLabels().equals(other.internalGetLabels())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } @@ -582,6 +843,14 @@ public int hashCode() { hash = (37 * hash) + SERVICES_FIELD_NUMBER; hash = (53 * hash) + getServicesList().hashCode(); } + if (getSubaccountsCount() > 0) { + hash = (37 * hash) + SUBACCOUNTS_FIELD_NUMBER; + hash = (53 * hash) + getSubaccountsList().hashCode(); + } + if (!internalGetLabels().getMap().isEmpty()) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + internalGetLabels().hashCode(); + } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; @@ -700,6 +969,26 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { .internal_static_google_cloud_billing_budgets_v1beta1_Filter_descriptor; } + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 6: + return internalGetLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMutableMapField(int number) { + switch (number) { + case 6: + return internalGetMutableLabels(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { @@ -733,6 +1022,9 @@ public Builder clear() { services_ = com.google.protobuf.LazyStringArrayList.EMPTY; bitField0_ = (bitField0_ & ~0x00000002); + subaccounts_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000004); + internalGetMutableLabels().clear(); return this; } @@ -772,6 +1064,13 @@ public com.google.cloud.billing.budgets.v1beta1.Filter buildPartial() { bitField0_ = (bitField0_ & ~0x00000002); } result.services_ = services_; + if (((bitField0_ & 0x00000004) != 0)) { + subaccounts_ = subaccounts_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000004); + } + result.subaccounts_ = subaccounts_; + result.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); onBuilt(); return result; } @@ -845,6 +1144,17 @@ public Builder mergeFrom(com.google.cloud.billing.budgets.v1beta1.Filter other) } onChanged(); } + if (!other.subaccounts_.isEmpty()) { + if (subaccounts_.isEmpty()) { + subaccounts_ = other.subaccounts_; + bitField0_ = (bitField0_ & ~0x00000004); + } else { + ensureSubaccountsIsMutable(); + subaccounts_.addAll(other.subaccounts_); + } + onChanged(); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); this.mergeUnknownFields(other.unknownFields); onChanged(); return this; @@ -1396,6 +1706,401 @@ public Builder addServicesBytes(com.google.protobuf.ByteString value) { return this; } + private com.google.protobuf.LazyStringList subaccounts_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureSubaccountsIsMutable() { + if (!((bitField0_ & 0x00000004) != 0)) { + subaccounts_ = new com.google.protobuf.LazyStringArrayList(subaccounts_); + bitField0_ |= 0x00000004; + } + } + /** + * + * + *
+     * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+     * that usage from only this set of subaccounts should be included in the
+     * budget. If a subaccount is set to the name of the master account, usage
+     * from the master account will be included. If omitted, the report will
+     * include usage from the master account and all subaccounts, if they exist.
+     * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return A list containing the subaccounts. + */ + public com.google.protobuf.ProtocolStringList getSubaccountsList() { + return subaccounts_.getUnmodifiableView(); + } + /** + * + * + *
+     * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+     * that usage from only this set of subaccounts should be included in the
+     * budget. If a subaccount is set to the name of the master account, usage
+     * from the master account will be included. If omitted, the report will
+     * include usage from the master account and all subaccounts, if they exist.
+     * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The count of subaccounts. + */ + public int getSubaccountsCount() { + return subaccounts_.size(); + } + /** + * + * + *
+     * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+     * that usage from only this set of subaccounts should be included in the
+     * budget. If a subaccount is set to the name of the master account, usage
+     * from the master account will be included. If omitted, the report will
+     * include usage from the master account and all subaccounts, if they exist.
+     * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the element to return. + * @return The subaccounts at the given index. + */ + public java.lang.String getSubaccounts(int index) { + return subaccounts_.get(index); + } + /** + * + * + *
+     * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+     * that usage from only this set of subaccounts should be included in the
+     * budget. If a subaccount is set to the name of the master account, usage
+     * from the master account will be included. If omitted, the report will
+     * include usage from the master account and all subaccounts, if they exist.
+     * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the value to return. + * @return The bytes of the subaccounts at the given index. + */ + public com.google.protobuf.ByteString getSubaccountsBytes(int index) { + return subaccounts_.getByteString(index); + } + /** + * + * + *
+     * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+     * that usage from only this set of subaccounts should be included in the
+     * budget. If a subaccount is set to the name of the master account, usage
+     * from the master account will be included. If omitted, the report will
+     * include usage from the master account and all subaccounts, if they exist.
+     * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index to set the value at. + * @param value The subaccounts to set. + * @return This builder for chaining. + */ + public Builder setSubaccounts(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSubaccountsIsMutable(); + subaccounts_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+     * that usage from only this set of subaccounts should be included in the
+     * budget. If a subaccount is set to the name of the master account, usage
+     * from the master account will be included. If omitted, the report will
+     * include usage from the master account and all subaccounts, if they exist.
+     * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The subaccounts to add. + * @return This builder for chaining. + */ + public Builder addSubaccounts(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureSubaccountsIsMutable(); + subaccounts_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+     * that usage from only this set of subaccounts should be included in the
+     * budget. If a subaccount is set to the name of the master account, usage
+     * from the master account will be included. If omitted, the report will
+     * include usage from the master account and all subaccounts, if they exist.
+     * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param values The subaccounts to add. + * @return This builder for chaining. + */ + public Builder addAllSubaccounts(java.lang.Iterable values) { + ensureSubaccountsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, subaccounts_); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+     * that usage from only this set of subaccounts should be included in the
+     * budget. If a subaccount is set to the name of the master account, usage
+     * from the master account will be included. If omitted, the report will
+     * include usage from the master account and all subaccounts, if they exist.
+     * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearSubaccounts() { + subaccounts_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000004); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+     * that usage from only this set of subaccounts should be included in the
+     * budget. If a subaccount is set to the name of the master account, usage
+     * from the master account will be included. If omitted, the report will
+     * include usage from the master account and all subaccounts, if they exist.
+     * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes of the subaccounts to add. + * @return This builder for chaining. + */ + public Builder addSubaccountsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureSubaccountsIsMutable(); + subaccounts_.add(value); + onChanged(); + return this; + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField + internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + private com.google.protobuf.MapField + internalGetMutableLabels() { + onChanged(); + ; + if (labels_ == null) { + labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + } + if (!labels_.isMutable()) { + labels_ = labels_.copy(); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+     * Optional. A single label and value pair specifying that usage from only this set of
+     * labeled resources should be included in the budget. Multiple entries or
+     * multiple values per entry are not allowed. If omitted, the report will
+     * include all labeled and unlabeled usage.
+     * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+     * Optional. A single label and value pair specifying that usage from only this set of
+     * labeled resources should be included in the budget. Multiple entries or
+     * multiple values per entry are not allowed. If omitted, the report will
+     * include all labeled and unlabeled usage.
+     * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+     * Optional. A single label and value pair specifying that usage from only this set of
+     * labeled resources should be included in the budget. Multiple entries or
+     * multiple values per entry are not allowed. If omitted, the report will
+     * include all labeled and unlabeled usage.
+     * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.ListValue getLabelsOrDefault( + java.lang.String key, com.google.protobuf.ListValue defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = + internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+     * Optional. A single label and value pair specifying that usage from only this set of
+     * labeled resources should be included in the budget. Multiple entries or
+     * multiple values per entry are not allowed. If omitted, the report will
+     * include all labeled and unlabeled usage.
+     * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.ListValue getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = + internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearLabels() { + internalGetMutableLabels().getMutableMap().clear(); + return this; + } + /** + * + * + *
+     * Optional. A single label and value pair specifying that usage from only this set of
+     * labeled resources should be included in the budget. Multiple entries or
+     * multiple values per entry are not allowed. If omitted, the report will
+     * include all labeled and unlabeled usage.
+     * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeLabels(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableLabels().getMutableMap().remove(key); + return this; + } + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableLabels() { + return internalGetMutableLabels().getMutableMap(); + } + /** + * + * + *
+     * Optional. A single label and value pair specifying that usage from only this set of
+     * labeled resources should be included in the budget. Multiple entries or
+     * multiple values per entry are not allowed. If omitted, the report will
+     * include all labeled and unlabeled usage.
+     * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putLabels(java.lang.String key, com.google.protobuf.ListValue value) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + if (value == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableLabels().getMutableMap().put(key, value); + return this; + } + /** + * + * + *
+     * Optional. A single label and value pair specifying that usage from only this set of
+     * labeled resources should be included in the budget. Multiple entries or
+     * multiple values per entry are not allowed. If omitted, the report will
+     * include all labeled and unlabeled usage.
+     * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putAllLabels( + java.util.Map values) { + internalGetMutableLabels().getMutableMap().putAll(values); + return this; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); diff --git a/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/FilterOrBuilder.java b/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/FilterOrBuilder.java index 8a026020..2be852fe 100644 --- a/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/FilterOrBuilder.java +++ b/proto-google-cloud-billingbudgets-v1beta1/src/main/java/com/google/cloud/billing/budgets/v1beta1/FilterOrBuilder.java @@ -189,4 +189,151 @@ public interface FilterOrBuilder * @return The bytes of the services at the given index. */ com.google.protobuf.ByteString getServicesBytes(int index); + + /** + * + * + *
+   * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+   * that usage from only this set of subaccounts should be included in the
+   * budget. If a subaccount is set to the name of the master account, usage
+   * from the master account will be included. If omitted, the report will
+   * include usage from the master account and all subaccounts, if they exist.
+   * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return A list containing the subaccounts. + */ + java.util.List getSubaccountsList(); + /** + * + * + *
+   * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+   * that usage from only this set of subaccounts should be included in the
+   * budget. If a subaccount is set to the name of the master account, usage
+   * from the master account will be included. If omitted, the report will
+   * include usage from the master account and all subaccounts, if they exist.
+   * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The count of subaccounts. + */ + int getSubaccountsCount(); + /** + * + * + *
+   * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+   * that usage from only this set of subaccounts should be included in the
+   * budget. If a subaccount is set to the name of the master account, usage
+   * from the master account will be included. If omitted, the report will
+   * include usage from the master account and all subaccounts, if they exist.
+   * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the element to return. + * @return The subaccounts at the given index. + */ + java.lang.String getSubaccounts(int index); + /** + * + * + *
+   * Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying
+   * that usage from only this set of subaccounts should be included in the
+   * budget. If a subaccount is set to the name of the master account, usage
+   * from the master account will be included. If omitted, the report will
+   * include usage from the master account and all subaccounts, if they exist.
+   * 
+ * + * repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the value to return. + * @return The bytes of the subaccounts at the given index. + */ + com.google.protobuf.ByteString getSubaccountsBytes(int index); + + /** + * + * + *
+   * Optional. A single label and value pair specifying that usage from only this set of
+   * labeled resources should be included in the budget. Multiple entries or
+   * multiple values per entry are not allowed. If omitted, the report will
+   * include all labeled and unlabeled usage.
+   * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getLabelsCount(); + /** + * + * + *
+   * Optional. A single label and value pair specifying that usage from only this set of
+   * labeled resources should be included in the budget. Multiple entries or
+   * multiple values per entry are not allowed. If omitted, the report will
+   * include all labeled and unlabeled usage.
+   * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + boolean containsLabels(java.lang.String key); + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getLabels(); + /** + * + * + *
+   * Optional. A single label and value pair specifying that usage from only this set of
+   * labeled resources should be included in the budget. Multiple entries or
+   * multiple values per entry are not allowed. If omitted, the report will
+   * include all labeled and unlabeled usage.
+   * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.Map getLabelsMap(); + /** + * + * + *
+   * Optional. A single label and value pair specifying that usage from only this set of
+   * labeled resources should be included in the budget. Multiple entries or
+   * multiple values per entry are not allowed. If omitted, the report will
+   * include all labeled and unlabeled usage.
+   * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.ListValue getLabelsOrDefault( + java.lang.String key, com.google.protobuf.ListValue defaultValue); + /** + * + * + *
+   * Optional. A single label and value pair specifying that usage from only this set of
+   * labeled resources should be included in the budget. Multiple entries or
+   * multiple values per entry are not allowed. If omitted, the report will
+   * include all labeled and unlabeled usage.
+   * 
+ * + * + * map<string, .google.protobuf.ListValue> labels = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.ListValue getLabelsOrThrow(java.lang.String key); } diff --git a/proto-google-cloud-billingbudgets-v1beta1/src/main/proto/google/cloud/billing/budgets/v1beta1/budget_model.proto b/proto-google-cloud-billingbudgets-v1beta1/src/main/proto/google/cloud/billing/budgets/v1beta1/budget_model.proto index d25cf332..fb2f1cfb 100644 --- a/proto-google-cloud-billingbudgets-v1beta1/src/main/proto/google/cloud/billing/budgets/v1beta1/budget_model.proto +++ b/proto-google-cloud-billingbudgets-v1beta1/src/main/proto/google/cloud/billing/budgets/v1beta1/budget_model.proto @@ -18,6 +18,7 @@ package google.cloud.billing.budgets.v1beta1; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; +import "google/protobuf/struct.proto"; import "google/type/money.proto"; option go_package = "google.golang.org/genproto/googleapis/cloud/billing/budgets/v1beta1;budgets"; @@ -176,4 +177,17 @@ message Filter { // The service names are available through the Catalog API: // https://cloud.google.com/billing/v1/how-tos/catalog-api. repeated string services = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying + // that usage from only this set of subaccounts should be included in the + // budget. If a subaccount is set to the name of the master account, usage + // from the master account will be included. If omitted, the report will + // include usage from the master account and all subaccounts, if they exist. + repeated string subaccounts = 5 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. A single label and value pair specifying that usage from only this set of + // labeled resources should be included in the budget. Multiple entries or + // multiple values per entry are not allowed. If omitted, the report will + // include all labeled and unlabeled usage. + map labels = 6 [(google.api.field_behavior) = OPTIONAL]; } diff --git a/proto-google-cloud-billingbudgets-v1beta1/src/main/proto/google/cloud/billing/budgets/v1beta1/budget_service.proto b/proto-google-cloud-billingbudgets-v1beta1/src/main/proto/google/cloud/billing/budgets/v1beta1/budget_service.proto index ab2b0714..e15ecf5c 100644 --- a/proto-google-cloud-billingbudgets-v1beta1/src/main/proto/google/cloud/billing/budgets/v1beta1/budget_service.proto +++ b/proto-google-cloud-billingbudgets-v1beta1/src/main/proto/google/cloud/billing/budgets/v1beta1/budget_service.proto @@ -47,7 +47,7 @@ service BudgetService { // Updates a budget and returns the updated budget. // // WARNING: There are some fields exposed on the Google Cloud Console that - // aren’t available on this API. Budget fields that are not exposed in + // aren't available on this API. Budget fields that are not exposed in // this API will not be changed by this method. rpc UpdateBudget(UpdateBudgetRequest) returns (Budget) { option (google.api.http) = { @@ -59,7 +59,7 @@ service BudgetService { // Returns a budget. // // WARNING: There are some fields exposed on the Google Cloud Console that - // aren’t available on this API. When reading from the API, you will not + // aren't available on this API. When reading from the API, you will not // see these fields in the return value, though they may have been set // in the Cloud Console. rpc GetBudget(GetBudgetRequest) returns (Budget) { @@ -71,7 +71,7 @@ service BudgetService { // Returns a list of budgets for a billing account. // // WARNING: There are some fields exposed on the Google Cloud Console that - // aren’t available on this API. When reading from the API, you will not + // aren't available on this API. When reading from the API, you will not // see these fields in the return value, though they may have been set // in the Cloud Console. rpc ListBudgets(ListBudgetsRequest) returns (ListBudgetsResponse) { diff --git a/synth.metadata b/synth.metadata index 4e879f42..9e580b1f 100644 --- a/synth.metadata +++ b/synth.metadata @@ -18,8 +18,8 @@ "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "aed11c01e52921613b9ee469c2d85f5f33175fb7", - "internalRef": "310660461" + "sha": "1b101f55aa42665b71684097256d2a64ff07c670", + "internalRef": "312682133" } }, {