Class: Google::Apis::ComputeBeta::LocationPolicy
- Inherits:
-
Object
- Object
- Google::Apis::ComputeBeta::LocationPolicy
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/compute_beta/classes.rb,
lib/google/apis/compute_beta/representations.rb,
lib/google/apis/compute_beta/representations.rb
Overview
Configuration for location policy among multiple possible locations (e.g. preferences for zone selection among zones in a single region).
Instance Attribute Summary collapse
-
#locations ⇒ Hash<String,Google::Apis::ComputeBeta::LocationPolicyLocation>
Location configurations mapped by location name.
-
#target_shape ⇒ String
Strategy for distributing VMs across zones in a region.
Instance Method Summary collapse
-
#initialize(**args) ⇒ LocationPolicy
constructor
A new instance of LocationPolicy.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ LocationPolicy
Returns a new instance of LocationPolicy.
23492 23493 23494 |
# File 'lib/google/apis/compute_beta/classes.rb', line 23492 def initialize(**args) update!(**args) end |
Instance Attribute Details
#locations ⇒ Hash<String,Google::Apis::ComputeBeta::LocationPolicyLocation>
Location configurations mapped by location name. Currently only zone names are
supported and must be represented as valid internal URLs, such as zones/us-
central1-a.
Corresponds to the JSON property locations
23485 23486 23487 |
# File 'lib/google/apis/compute_beta/classes.rb', line 23485 def locations @locations end |
#target_shape ⇒ String
Strategy for distributing VMs across zones in a region.
Corresponds to the JSON property targetShape
23490 23491 23492 |
# File 'lib/google/apis/compute_beta/classes.rb', line 23490 def target_shape @target_shape end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
23497 23498 23499 23500 |
# File 'lib/google/apis/compute_beta/classes.rb', line 23497 def update!(**args) @locations = args[:locations] if args.key?(:locations) @target_shape = args[:target_shape] if args.key?(:target_shape) end |