Class: Google::Apis::ReplicapoolV1beta1::DiskAttachment

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

Overview

Specifies how to attach a disk to a Replica.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ DiskAttachment

Returns a new instance of DiskAttachment



110
111
112
# File 'generated/google/apis/replicapool_v1beta1/classes.rb', line 110

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

Instance Attribute Details

#device_nameString

The device name of this disk. Corresponds to the JSON property deviceName

Returns:

  • (String)


102
103
104
# File 'generated/google/apis/replicapool_v1beta1/classes.rb', line 102

def device_name
  @device_name
end

#indexFixnum

A zero-based index to assign to this disk, where 0 is reserved for the boot disk. If not specified, this is assigned by the server. Corresponds to the JSON property index

Returns:

  • (Fixnum)


108
109
110
# File 'generated/google/apis/replicapool_v1beta1/classes.rb', line 108

def index
  @index
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



115
116
117
118
# File 'generated/google/apis/replicapool_v1beta1/classes.rb', line 115

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