Class Filter.Builder (2.7.0)

public static final class Filter.Builder extends GeneratedMessageV3.Builder<Filter.Builder> implements FilterOrBuilder

A filter for a budget, limiting the scope of the cost to calculate.

Protobuf type google.cloud.billing.budgets.v1.Filter

Implements

FilterOrBuilder

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addAllCreditTypes(Iterable<String> values)

public Filter.Builder addAllCreditTypes(Iterable<String> values)

Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values. If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

repeated string credit_types = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valuesIterable<String>

The creditTypes to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addAllProjects(Iterable<String> values)

public Filter.Builder addAllProjects(Iterable<String> values)

Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report will include all usage for the billing account, regardless of which project the usage occurred on. Only zero or one project can be specified currently.

repeated string projects = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valuesIterable<String>

The projects to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addAllServices(Iterable<String> values)

public Filter.Builder addAllServices(Iterable<String> values)

Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report will include usage for all the services. 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];

Parameter
NameDescription
valuesIterable<String>

The services to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addAllSubaccounts(Iterable<String> values)

public Filter.Builder addAllSubaccounts(Iterable<String> values)

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 parent account, usage from the parent account will be included. If the field is omitted, the report will include usage from the parent account and all subaccounts, if they exist.

repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valuesIterable<String>

The subaccounts to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addCreditTypes(String value)

public Filter.Builder addCreditTypes(String value)

Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values. If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

repeated string credit_types = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueString

The creditTypes to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addCreditTypesBytes(ByteString value)

public Filter.Builder addCreditTypesBytes(ByteString value)

Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values. If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

repeated string credit_types = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueByteString

The bytes of the creditTypes to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addProjects(String value)

public Filter.Builder addProjects(String value)

Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report will include all usage for the billing account, regardless of which project the usage occurred on. Only zero or one project can be specified currently.

repeated string projects = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueString

The projects to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addProjectsBytes(ByteString value)

public Filter.Builder addProjectsBytes(ByteString value)

Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report will include all usage for the billing account, regardless of which project the usage occurred on. Only zero or one project can be specified currently.

repeated string projects = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueByteString

The bytes of the projects to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Filter.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Filter.Builder
Overrides

addServices(String value)

public Filter.Builder addServices(String value)

Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report will include usage for all the services. 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];

Parameter
NameDescription
valueString

The services to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addServicesBytes(ByteString value)

public Filter.Builder addServicesBytes(ByteString value)

Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report will include usage for all the services. 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];

Parameter
NameDescription
valueByteString

The bytes of the services to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addSubaccounts(String value)

public Filter.Builder addSubaccounts(String value)

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 parent account, usage from the parent account will be included. If the field is omitted, the report will include usage from the parent account and all subaccounts, if they exist.

repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueString

The subaccounts to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

addSubaccountsBytes(ByteString value)

public Filter.Builder addSubaccountsBytes(ByteString value)

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 parent account, usage from the parent account will be included. If the field is omitted, the report will include usage from the parent account and all subaccounts, if they exist.

repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueByteString

The bytes of the subaccounts to add.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

build()

public Filter build()
Returns
TypeDescription
Filter

buildPartial()

public Filter buildPartial()
Returns
TypeDescription
Filter

clear()

public Filter.Builder clear()
Returns
TypeDescription
Filter.Builder
Overrides

clearCalendarPeriod()

public Filter.Builder clearCalendarPeriod()

Optional. Specifies to track usage for recurring calendar period. For example, assume that CalendarPeriod.QUARTER is set. The budget will track usage from April 1 to June 30, when the current calendar month is April, May, June. After that, it will track usage from July 1 to September 30 when the current calendar month is July, August, September, so on.

.google.cloud.billing.budgets.v1.CalendarPeriod calendar_period = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Filter.Builder

This builder for chaining.

clearCreditTypes()

public Filter.Builder clearCreditTypes()

Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values. If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

repeated string credit_types = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Filter.Builder

This builder for chaining.

clearCreditTypesTreatment()

public Filter.Builder clearCreditTypesTreatment()

Optional. If not set, default behavior is INCLUDE_ALL_CREDITS.

.google.cloud.billing.budgets.v1.Filter.CreditTypesTreatment credit_types_treatment = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Filter.Builder

This builder for chaining.

clearCustomPeriod()

public Filter.Builder clearCustomPeriod()

Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur.

.google.cloud.billing.budgets.v1.CustomPeriod custom_period = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Filter.Builder

clearField(Descriptors.FieldDescriptor field)

public Filter.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
Filter.Builder
Overrides

clearLabels()

public Filter.Builder clearLabels()
Returns
TypeDescription
Filter.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

public Filter.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
Filter.Builder
Overrides

clearProjects()

public Filter.Builder clearProjects()

Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report will include all usage for the billing account, regardless of which project the usage occurred on. Only zero or one project can be specified currently.

repeated string projects = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Filter.Builder

This builder for chaining.

clearServices()

public Filter.Builder clearServices()

Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report will include usage for all the services. 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];

Returns
TypeDescription
Filter.Builder

This builder for chaining.

clearSubaccounts()

public Filter.Builder clearSubaccounts()

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 parent account, usage from the parent account will be included. If the field is omitted, the report will include usage from the parent account and all subaccounts, if they exist.

repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Filter.Builder

This builder for chaining.

clearUsagePeriod()

public Filter.Builder clearUsagePeriod()
Returns
TypeDescription
Filter.Builder

clone()

public Filter.Builder clone()
Returns
TypeDescription
Filter.Builder
Overrides

containsLabels(String key)

public boolean containsLabels(String key)

Optional. A single label and value pair specifying that usage from only this set of labeled resources should be included in the budget. Currently, 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];

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

getCalendarPeriod()

public CalendarPeriod getCalendarPeriod()

Optional. Specifies to track usage for recurring calendar period. For example, assume that CalendarPeriod.QUARTER is set. The budget will track usage from April 1 to June 30, when the current calendar month is April, May, June. After that, it will track usage from July 1 to September 30 when the current calendar month is July, August, September, so on.

.google.cloud.billing.budgets.v1.CalendarPeriod calendar_period = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
CalendarPeriod

The calendarPeriod.

getCalendarPeriodValue()

public int getCalendarPeriodValue()

Optional. Specifies to track usage for recurring calendar period. For example, assume that CalendarPeriod.QUARTER is set. The budget will track usage from April 1 to June 30, when the current calendar month is April, May, June. After that, it will track usage from July 1 to September 30 when the current calendar month is July, August, September, so on.

.google.cloud.billing.budgets.v1.CalendarPeriod calendar_period = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

The enum numeric value on the wire for calendarPeriod.

getCreditTypes(int index)

public String getCreditTypes(int index)

Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values. If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

repeated string credit_types = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The creditTypes at the given index.

getCreditTypesBytes(int index)

public ByteString getCreditTypesBytes(int index)

Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values. If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

repeated string credit_types = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the creditTypes at the given index.

getCreditTypesCount()

public int getCreditTypesCount()

Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values. If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

repeated string credit_types = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

The count of creditTypes.

getCreditTypesList()

public ProtocolStringList getCreditTypesList()

Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values. If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

repeated string credit_types = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ProtocolStringList

A list containing the creditTypes.

getCreditTypesTreatment()

public Filter.CreditTypesTreatment getCreditTypesTreatment()

Optional. If not set, default behavior is INCLUDE_ALL_CREDITS.

.google.cloud.billing.budgets.v1.Filter.CreditTypesTreatment credit_types_treatment = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Filter.CreditTypesTreatment

The creditTypesTreatment.

getCreditTypesTreatmentValue()

public int getCreditTypesTreatmentValue()

Optional. If not set, default behavior is INCLUDE_ALL_CREDITS.

.google.cloud.billing.budgets.v1.Filter.CreditTypesTreatment credit_types_treatment = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

The enum numeric value on the wire for creditTypesTreatment.

getCustomPeriod()

public CustomPeriod getCustomPeriod()

Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur.

.google.cloud.billing.budgets.v1.CustomPeriod custom_period = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
CustomPeriod

The customPeriod.

getCustomPeriodBuilder()

public CustomPeriod.Builder getCustomPeriodBuilder()

Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur.

.google.cloud.billing.budgets.v1.CustomPeriod custom_period = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
CustomPeriod.Builder

getCustomPeriodOrBuilder()

public CustomPeriodOrBuilder getCustomPeriodOrBuilder()

Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur.

.google.cloud.billing.budgets.v1.CustomPeriod custom_period = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
CustomPeriodOrBuilder

getDefaultInstanceForType()

public Filter getDefaultInstanceForType()
Returns
TypeDescription
Filter

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getLabels()

public Map<String,ListValue> getLabels()

Use #getLabelsMap() instead.

Returns
TypeDescription
Map<String,ListValue>

getLabelsCount()

public 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. Currently, 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];

Returns
TypeDescription
int

getLabelsMap()

public Map<String,ListValue> getLabelsMap()

Optional. A single label and value pair specifying that usage from only this set of labeled resources should be included in the budget. Currently, 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];

Returns
TypeDescription
Map<String,ListValue>

getLabelsOrDefault(String key, ListValue defaultValue)

public ListValue getLabelsOrDefault(String key, 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. Currently, 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];

Parameters
NameDescription
keyString
defaultValueListValue
Returns
TypeDescription
ListValue

getLabelsOrThrow(String key)

public ListValue getLabelsOrThrow(String key)

Optional. A single label and value pair specifying that usage from only this set of labeled resources should be included in the budget. Currently, 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];

Parameter
NameDescription
keyString
Returns
TypeDescription
ListValue

getMutableLabels()

public Map<String,ListValue> getMutableLabels()

Use alternate mutation accessors instead.

Returns
TypeDescription
Map<String,ListValue>

getProjects(int index)

public String getProjects(int index)

Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report will include all usage for the billing account, regardless of which project the usage occurred on. Only zero or one project can be specified currently.

repeated string projects = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The projects at the given index.

getProjectsBytes(int index)

public ByteString getProjectsBytes(int index)

Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report will include all usage for the billing account, regardless of which project the usage occurred on. Only zero or one project can be specified currently.

repeated string projects = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the projects at the given index.

getProjectsCount()

public int getProjectsCount()

Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report will include all usage for the billing account, regardless of which project the usage occurred on. Only zero or one project can be specified currently.

repeated string projects = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

The count of projects.

getProjectsList()

public ProtocolStringList getProjectsList()

Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report will include all usage for the billing account, regardless of which project the usage occurred on. Only zero or one project can be specified currently.

repeated string projects = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ProtocolStringList

A list containing the projects.

getServices(int index)

public String getServices(int index)

Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report will include usage for all the services. 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];

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The services at the given index.

getServicesBytes(int index)

public ByteString getServicesBytes(int index)

Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report will include usage for all the services. 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];

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the services at the given index.

getServicesCount()

public int getServicesCount()

Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report will include usage for all the services. 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];

Returns
TypeDescription
int

The count of services.

getServicesList()

public ProtocolStringList getServicesList()

Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report will include usage for all the services. 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];

Returns
TypeDescription
ProtocolStringList

A list containing the services.

getSubaccounts(int index)

public 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 parent account, usage from the parent account will be included. If the field is omitted, the report will include usage from the parent account and all subaccounts, if they exist.

repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The subaccounts at the given index.

getSubaccountsBytes(int index)

public ByteString getSubaccountsBytes(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 parent account, usage from the parent account will be included. If the field is omitted, the report will include usage from the parent account and all subaccounts, if they exist.

repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the subaccounts at the given index.

getSubaccountsCount()

public 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 parent account, usage from the parent account will be included. If the field is omitted, the report will include usage from the parent account and all subaccounts, if they exist.

repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

The count of subaccounts.

getSubaccountsList()

public ProtocolStringList 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 parent account, usage from the parent account will be included. If the field is omitted, the report will include usage from the parent account and all subaccounts, if they exist.

repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
ProtocolStringList

A list containing the subaccounts.

getUsagePeriodCase()

public Filter.UsagePeriodCase getUsagePeriodCase()
Returns
TypeDescription
Filter.UsagePeriodCase

hasCalendarPeriod()

public boolean hasCalendarPeriod()

Optional. Specifies to track usage for recurring calendar period. For example, assume that CalendarPeriod.QUARTER is set. The budget will track usage from April 1 to June 30, when the current calendar month is April, May, June. After that, it will track usage from July 1 to September 30 when the current calendar month is July, August, September, so on.

.google.cloud.billing.budgets.v1.CalendarPeriod calendar_period = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
boolean

Whether the calendarPeriod field is set.

hasCustomPeriod()

public boolean hasCustomPeriod()

Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur.

.google.cloud.billing.budgets.v1.CustomPeriod custom_period = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
boolean

Whether the customPeriod field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapField(int number)

protected MapField internalGetMapField(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
MapField
Overrides

internalGetMutableMapField(int number)

protected MapField internalGetMutableMapField(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
MapField
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeCustomPeriod(CustomPeriod value)

public Filter.Builder mergeCustomPeriod(CustomPeriod value)

Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur.

.google.cloud.billing.budgets.v1.CustomPeriod custom_period = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueCustomPeriod
Returns
TypeDescription
Filter.Builder

mergeFrom(Filter other)

public Filter.Builder mergeFrom(Filter other)
Parameter
NameDescription
otherFilter
Returns
TypeDescription
Filter.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Filter.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Filter.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public Filter.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
Filter.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Filter.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Filter.Builder
Overrides

putAllLabels(Map<String,ListValue> values)

public Filter.Builder putAllLabels(Map<String,ListValue> values)

Optional. A single label and value pair specifying that usage from only this set of labeled resources should be included in the budget. Currently, 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];

Parameter
NameDescription
valuesMap<String,ListValue>
Returns
TypeDescription
Filter.Builder

putLabels(String key, ListValue value)

public Filter.Builder putLabels(String key, ListValue value)

Optional. A single label and value pair specifying that usage from only this set of labeled resources should be included in the budget. Currently, 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];

Parameters
NameDescription
keyString
valueListValue
Returns
TypeDescription
Filter.Builder

removeLabels(String key)

public Filter.Builder removeLabels(String key)

Optional. A single label and value pair specifying that usage from only this set of labeled resources should be included in the budget. Currently, 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];

Parameter
NameDescription
keyString
Returns
TypeDescription
Filter.Builder

setCalendarPeriod(CalendarPeriod value)

public Filter.Builder setCalendarPeriod(CalendarPeriod value)

Optional. Specifies to track usage for recurring calendar period. For example, assume that CalendarPeriod.QUARTER is set. The budget will track usage from April 1 to June 30, when the current calendar month is April, May, June. After that, it will track usage from July 1 to September 30 when the current calendar month is July, August, September, so on.

.google.cloud.billing.budgets.v1.CalendarPeriod calendar_period = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueCalendarPeriod

The calendarPeriod to set.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

setCalendarPeriodValue(int value)

public Filter.Builder setCalendarPeriodValue(int value)

Optional. Specifies to track usage for recurring calendar period. For example, assume that CalendarPeriod.QUARTER is set. The budget will track usage from April 1 to June 30, when the current calendar month is April, May, June. After that, it will track usage from July 1 to September 30 when the current calendar month is July, August, September, so on.

.google.cloud.billing.budgets.v1.CalendarPeriod calendar_period = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueint

The enum numeric value on the wire for calendarPeriod to set.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

setCreditTypes(int index, String value)

public Filter.Builder setCreditTypes(int index, String value)

Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values. If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

repeated string credit_types = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The creditTypes to set.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

setCreditTypesTreatment(Filter.CreditTypesTreatment value)

public Filter.Builder setCreditTypesTreatment(Filter.CreditTypesTreatment value)

Optional. If not set, default behavior is INCLUDE_ALL_CREDITS.

.google.cloud.billing.budgets.v1.Filter.CreditTypesTreatment credit_types_treatment = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueFilter.CreditTypesTreatment

The creditTypesTreatment to set.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

setCreditTypesTreatmentValue(int value)

public Filter.Builder setCreditTypesTreatmentValue(int value)

Optional. If not set, default behavior is INCLUDE_ALL_CREDITS.

.google.cloud.billing.budgets.v1.Filter.CreditTypesTreatment credit_types_treatment = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueint

The enum numeric value on the wire for creditTypesTreatment to set.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

setCustomPeriod(CustomPeriod value)

public Filter.Builder setCustomPeriod(CustomPeriod value)

Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur.

.google.cloud.billing.budgets.v1.CustomPeriod custom_period = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
valueCustomPeriod
Returns
TypeDescription
Filter.Builder

setCustomPeriod(CustomPeriod.Builder builderForValue)

public Filter.Builder setCustomPeriod(CustomPeriod.Builder builderForValue)

Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur.

.google.cloud.billing.budgets.v1.CustomPeriod custom_period = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
NameDescription
builderForValueCustomPeriod.Builder
Returns
TypeDescription
Filter.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public Filter.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Filter.Builder
Overrides

setProjects(int index, String value)

public Filter.Builder setProjects(int index, String value)

Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report will include all usage for the billing account, regardless of which project the usage occurred on. Only zero or one project can be specified currently.

repeated string projects = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The projects to set.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public Filter.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
Filter.Builder
Overrides

setServices(int index, String value)

public Filter.Builder setServices(int index, String value)

Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report will include usage for all the services. 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];

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The services to set.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

setSubaccounts(int index, String value)

public Filter.Builder setSubaccounts(int index, String value)

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 parent account, usage from the parent account will be included. If the field is omitted, the report will include usage from the parent account and all subaccounts, if they exist.

repeated string subaccounts = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The subaccounts to set.

Returns
TypeDescription
Filter.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final Filter.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Filter.Builder
Overrides