Class: Google::Apis::ContainerV1beta1::ReservationAffinity
- Inherits:
-
Object
- Object
- Google::Apis::ContainerV1beta1::ReservationAffinity
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/container_v1beta1/classes.rb,
lib/google/apis/container_v1beta1/representations.rb,
lib/google/apis/container_v1beta1/representations.rb
Overview
ReservationAffinity is the configuration of desired reservation which instances could take capacity from.
Instance Attribute Summary collapse
-
#consume_reservation_type ⇒ String
Corresponds to the type of reservation consumption.
-
#key ⇒ String
Corresponds to the label key of a reservation resource.
-
#values ⇒ Array<String>
Corresponds to the label value(s) of reservation resource(s).
Instance Method Summary collapse
-
#initialize(**args) ⇒ ReservationAffinity
constructor
A new instance of ReservationAffinity.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ ReservationAffinity
Returns a new instance of ReservationAffinity.
4149 4150 4151 |
# File 'lib/google/apis/container_v1beta1/classes.rb', line 4149 def initialize(**args) update!(**args) end |
Instance Attribute Details
#consume_reservation_type ⇒ String
Corresponds to the type of reservation consumption.
Corresponds to the JSON property consumeReservationType
4135 4136 4137 |
# File 'lib/google/apis/container_v1beta1/classes.rb', line 4135 def consume_reservation_type @consume_reservation_type end |
#key ⇒ String
Corresponds to the label key of a reservation resource. To target a
SPECIFIC_RESERVATION by name, specify "googleapis.com/reservation-name" as the
key and specify the name of your reservation as its value.
Corresponds to the JSON property key
4142 4143 4144 |
# File 'lib/google/apis/container_v1beta1/classes.rb', line 4142 def key @key end |
#values ⇒ Array<String>
Corresponds to the label value(s) of reservation resource(s).
Corresponds to the JSON property values
4147 4148 4149 |
# File 'lib/google/apis/container_v1beta1/classes.rb', line 4147 def values @values end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
4154 4155 4156 4157 4158 |
# File 'lib/google/apis/container_v1beta1/classes.rb', line 4154 def update!(**args) @consume_reservation_type = args[:consume_reservation_type] if args.key?(:consume_reservation_type) @key = args[:key] if args.key?(:key) @values = args[:values] if args.key?(:values) end |