Class: Google::Apis::BillingbudgetsV1::GoogleCloudBillingBudgetsV1Filter
- Inherits:
-
Object
- Object
- Google::Apis::BillingbudgetsV1::GoogleCloudBillingBudgetsV1Filter
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/billingbudgets_v1/classes.rb,
generated/google/apis/billingbudgets_v1/representations.rb,
generated/google/apis/billingbudgets_v1/representations.rb
Overview
A filter for a budget, limiting the scope of the cost to calculate.
Instance Attribute Summary collapse
-
#credit_types ⇒ Array<String>
Optional.
-
#credit_types_treatment ⇒ String
Optional.
-
#labels ⇒ Hash<String,Array<Object>>
Optional.
-
#projects ⇒ Array<String>
Optional.
-
#services ⇒ Array<String>
Optional.
-
#subaccounts ⇒ Array<String>
Optional.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GoogleCloudBillingBudgetsV1Filter
constructor
A new instance of GoogleCloudBillingBudgetsV1Filter.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ GoogleCloudBillingBudgetsV1Filter
Returns a new instance of GoogleCloudBillingBudgetsV1Filter.
172 173 174 |
# File 'generated/google/apis/billingbudgets_v1/classes.rb', line 172 def initialize(**args) update!(**args) end |
Instance Attribute Details
#credit_types ⇒ Array<String>
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. If Filter.credit_types_treatment is not
INCLUDE_SPECIFIED_CREDITS, this field must be empty. See a list of acceptable
credit type values.
Corresponds to the JSON property creditTypes
130 131 132 |
# File 'generated/google/apis/billingbudgets_v1/classes.rb', line 130 def credit_types @credit_types end |
#credit_types_treatment ⇒ String
Optional. If not set, default behavior is INCLUDE_ALL_CREDITS
.
Corresponds to the JSON property creditTypesTreatment
135 136 137 |
# File 'generated/google/apis/billingbudgets_v1/classes.rb', line 135 def credit_types_treatment @credit_types_treatment end |
#labels ⇒ Hash<String,Array<Object>>
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.
Corresponds to the JSON property labels
143 144 145 |
# File 'generated/google/apis/billingbudgets_v1/classes.rb', line 143 def labels @labels end |
#projects ⇒ Array<String>
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.
Corresponds to the JSON property
projects`
152 153 154 |
# File 'generated/google/apis/billingbudgets_v1/classes.rb', line 152 def projects @projects end |
#services ⇒ Array<String>
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.
Corresponds to the JSON property
services`
161 162 163 |
# File 'generated/google/apis/billingbudgets_v1/classes.rb', line 161 def services @services end |
#subaccounts ⇒ Array<String>
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.
Corresponds to the JSON property
subaccounts`
170 171 172 |
# File 'generated/google/apis/billingbudgets_v1/classes.rb', line 170 def subaccounts @subaccounts end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
177 178 179 180 181 182 183 184 |
# File 'generated/google/apis/billingbudgets_v1/classes.rb', line 177 def update!(**args) @credit_types = args[:credit_types] if args.key?(:credit_types) @credit_types_treatment = args[:credit_types_treatment] if args.key?(:credit_types_treatment) @labels = args[:labels] if args.key?(:labels) @projects = args[:projects] if args.key?(:projects) @services = args[:services] if args.key?(:services) @subaccounts = args[:subaccounts] if args.key?(:subaccounts) end |