Class: Google::Apis::TpuV2alpha1::Guaranteed

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/tpu_v2alpha1/classes.rb,
lib/google/apis/tpu_v2alpha1/representations.rb,
lib/google/apis/tpu_v2alpha1/representations.rb

Overview

Guaranteed tier definition.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Guaranteed

Returns a new instance of Guaranteed.



295
296
297
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 295

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#min_durationString

Optional. Defines the minimum duration of the guarantee. If specified, the requested resources will only be provisioned if they can be allocated for at least the given duration. Corresponds to the JSON property minDuration

Returns:

  • (String)


287
288
289
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 287

def min_duration
  @min_duration
end

#reservedBoolean Also known as: reserved?

Optional. Specifies the request should be scheduled on reserved capacity. Corresponds to the JSON property reserved

Returns:

  • (Boolean)


292
293
294
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 292

def reserved
  @reserved
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



300
301
302
303
# File 'lib/google/apis/tpu_v2alpha1/classes.rb', line 300

def update!(**args)
  @min_duration = args[:min_duration] if args.key?(:min_duration)
  @reserved = args[:reserved] if args.key?(:reserved)
end