Class: OvirtSDK4::OpenStackVolumeProvider

Inherits:
OpenStackProvider show all
Defined in:
lib/ovirtsdk4/types.rb,
lib/ovirtsdk4/types.rb

Instance Method Summary (collapse)

Methods included from Type

#href, #href=

Constructor Details

- (OpenStackVolumeProvider) initialize(opts = {})

Creates a new instance of the OvirtSDK4::OpenStackVolumeProvider class.

Parameters:

  • opts (Hash) (defaults to: {})

    A hash containing the attributes of the object. The keys of the hash should be symbols corresponding to the names of the attributes. The values of the hash should be the values of the attributes.

Options Hash (opts):

  • :authentication_keys (Array<OpenstackVolumeAuthenticationKey>, Array<Hash>)

    The values of attribute authentication_keys.

  • :authentication_url (String)

    The value of attribute authentication_url.

  • :certificates (Array<Certificate>, Array<Hash>)

    The values of attribute certificates.

  • :comment (String)

    The value of attribute comment.

  • :data_center (DataCenter, Hash)

    The value of attribute data_center.

  • :description (String)

    The value of attribute description.

  • :id (String)

    The value of attribute id.

  • :name (String)

    The value of attribute name.

  • :password (String)

    The value of attribute password.

  • :properties (Array<Property>, Array<Hash>)

    The values of attribute properties.

  • :requires_authentication (Boolean)

    The value of attribute requires_authentication.

  • :tenant_name (String)

    The value of attribute tenant_name.

  • :url (String)

    The value of attribute url.

  • :username (String)

    The value of attribute username.

  • :volume_types (Array<OpenStackVolumeType>, Array<Hash>)

    The values of attribute volume_types.



36555
36556
36557
36558
36559
36560
36561
36562
36563
36564
36565
36566
36567
36568
36569
36570
36571
36572
# File 'lib/ovirtsdk4/types.rb', line 36555

def initialize(opts = {})
  super(opts)
  self.authentication_keys = opts[:authentication_keys]
  self.authentication_url = opts[:authentication_url]
  self.certificates = opts[:certificates]
  self.comment = opts[:comment]
  self.data_center = opts[:data_center]
  self.description = opts[:description]
  self.id = opts[:id]
  self.name = opts[:name]
  self.password = opts[:password]
  self.properties = opts[:properties]
  self.requires_authentication = opts[:requires_authentication]
  self.tenant_name = opts[:tenant_name]
  self.url = opts[:url]
  self.username = opts[:username]
  self.volume_types = opts[:volume_types]
end

Instance Method Details

- (Array<OpenstackVolumeAuthenticationKey>) authentication_keys

Returns the value of the authentication_keys attribute.



36217
36218
36219
# File 'lib/ovirtsdk4/types.rb', line 36217

def authentication_keys
  return @authentication_keys
end

- (Object) authentication_keys=(list)

Sets the value of the authentication_keys attribute.

Parameters:



36225
36226
36227
36228
36229
36230
36231
36232
36233
36234
36235
# File 'lib/ovirtsdk4/types.rb', line 36225

def authentication_keys=(list)
  if list.class == Array
    list = List.new(list)
    list.each_with_index do |value, index|
      if value.is_a?(Hash)
        list[index] = OpenstackVolumeAuthenticationKey.new(value)
      end
    end
  end
  @authentication_keys = list
end

- (String) authentication_url

Returns the value of the authentication_url attribute.

Returns:

  • (String)


36242
36243
36244
# File 'lib/ovirtsdk4/types.rb', line 36242

def authentication_url
  return @authentication_url
end

- (Object) authentication_url=(value)

Sets the value of the authentication_url attribute.

Parameters:

  • value (String)


36251
36252
36253
# File 'lib/ovirtsdk4/types.rb', line 36251

def authentication_url=(value)
  @authentication_url = value
end

- (Array<Certificate>) certificates

Returns the value of the certificates attribute.

Returns:



36260
36261
36262
# File 'lib/ovirtsdk4/types.rb', line 36260

def certificates
  return @certificates
end

- (Object) certificates=(list)

Sets the value of the certificates attribute.

Parameters:



36268
36269
36270
36271
36272
36273
36274
36275
36276
36277
36278
# File 'lib/ovirtsdk4/types.rb', line 36268

def certificates=(list)
  if list.class == Array
    list = List.new(list)
    list.each_with_index do |value, index|
      if value.is_a?(Hash)
        list[index] = Certificate.new(value)
      end
    end
  end
  @certificates = list
end

- (String) comment

Returns the value of the comment attribute.

Returns:

  • (String)


36285
36286
36287
# File 'lib/ovirtsdk4/types.rb', line 36285

def comment
  return @comment
end

- (Object) comment=(value)

Sets the value of the comment attribute.

Parameters:

  • value (String)


36294
36295
36296
# File 'lib/ovirtsdk4/types.rb', line 36294

def comment=(value)
  @comment = value
end

- (DataCenter) data_center

Returns the value of the data_center attribute.

Returns:



36303
36304
36305
# File 'lib/ovirtsdk4/types.rb', line 36303

def data_center
  return @data_center
end

- (Object) data_center=(value)

Sets the value of the data_center attribute.

The value parameter can be an instance of DataCenter or a hash. If it is a hash then a new instance will be created passing the hash as the opts parameter to the constructor.

Parameters:



36316
36317
36318
36319
36320
36321
# File 'lib/ovirtsdk4/types.rb', line 36316

def data_center=(value)
  if value.is_a?(Hash)
    value = DataCenter.new(value)
  end
  @data_center = value
end

- (String) description

Returns the value of the description attribute.

Returns:

  • (String)


36328
36329
36330
# File 'lib/ovirtsdk4/types.rb', line 36328

def description
  return @description
end

- (Object) description=(value)

Sets the value of the description attribute.

Parameters:

  • value (String)


36337
36338
36339
# File 'lib/ovirtsdk4/types.rb', line 36337

def description=(value)
  @description = value
end

- (String) id

Returns the value of the id attribute.

Returns:

  • (String)


36346
36347
36348
# File 'lib/ovirtsdk4/types.rb', line 36346

def id
  return @id
end

- (Object) id=(value)

Sets the value of the id attribute.

Parameters:

  • value (String)


36355
36356
36357
# File 'lib/ovirtsdk4/types.rb', line 36355

def id=(value)
  @id = value
end

- (String) name

Returns the value of the name attribute.

Returns:

  • (String)


36364
36365
36366
# File 'lib/ovirtsdk4/types.rb', line 36364

def name
  return @name
end

- (Object) name=(value)

Sets the value of the name attribute.

Parameters:

  • value (String)


36373
36374
36375
# File 'lib/ovirtsdk4/types.rb', line 36373

def name=(value)
  @name = value
end

- (String) password

Returns the value of the password attribute.

Returns:

  • (String)


36382
36383
36384
# File 'lib/ovirtsdk4/types.rb', line 36382

def password
  return @password
end

- (Object) password=(value)

Sets the value of the password attribute.

Parameters:

  • value (String)


36391
36392
36393
# File 'lib/ovirtsdk4/types.rb', line 36391

def password=(value)
  @password = value
end

- (Array<Property>) properties

Returns the value of the properties attribute.

Returns:



36400
36401
36402
# File 'lib/ovirtsdk4/types.rb', line 36400

def properties
  return @properties
end

- (Object) properties=(list)

Sets the value of the properties attribute.

Parameters:



36408
36409
36410
36411
36412
36413
36414
36415
36416
36417
36418
# File 'lib/ovirtsdk4/types.rb', line 36408

def properties=(list)
  if list.class == Array
    list = List.new(list)
    list.each_with_index do |value, index|
      if value.is_a?(Hash)
        list[index] = Property.new(value)
      end
    end
  end
  @properties = list
end

- (Boolean) requires_authentication

Returns the value of the requires_authentication attribute.

Returns:

  • (Boolean)


36425
36426
36427
# File 'lib/ovirtsdk4/types.rb', line 36425

def requires_authentication
  return @requires_authentication
end

- (Object) requires_authentication=(value)

Sets the value of the requires_authentication attribute.

Parameters:

  • value (Boolean)


36434
36435
36436
# File 'lib/ovirtsdk4/types.rb', line 36434

def requires_authentication=(value)
  @requires_authentication = value
end

- (String) tenant_name

Returns the value of the tenant_name attribute.

Returns:

  • (String)


36443
36444
36445
# File 'lib/ovirtsdk4/types.rb', line 36443

def tenant_name
  return @tenant_name
end

- (Object) tenant_name=(value)

Sets the value of the tenant_name attribute.

Parameters:

  • value (String)


36452
36453
36454
# File 'lib/ovirtsdk4/types.rb', line 36452

def tenant_name=(value)
  @tenant_name = value
end

- (String) url

Returns the value of the url attribute.

Returns:

  • (String)


36461
36462
36463
# File 'lib/ovirtsdk4/types.rb', line 36461

def url
  return @url
end

- (Object) url=(value)

Sets the value of the url attribute.

Parameters:

  • value (String)


36470
36471
36472
# File 'lib/ovirtsdk4/types.rb', line 36470

def url=(value)
  @url = value
end

- (String) username

Returns the value of the username attribute.

Returns:

  • (String)


36479
36480
36481
# File 'lib/ovirtsdk4/types.rb', line 36479

def username
  return @username
end

- (Object) username=(value)

Sets the value of the username attribute.

Parameters:

  • value (String)


36488
36489
36490
# File 'lib/ovirtsdk4/types.rb', line 36488

def username=(value)
  @username = value
end

- (Array<OpenStackVolumeType>) volume_types

Returns the value of the volume_types attribute.

Returns:



36497
36498
36499
# File 'lib/ovirtsdk4/types.rb', line 36497

def volume_types
  return @volume_types
end

- (Object) volume_types=(list)

Sets the value of the volume_types attribute.

Parameters:



36505
36506
36507
36508
36509
36510
36511
36512
36513
36514
36515
# File 'lib/ovirtsdk4/types.rb', line 36505

def volume_types=(list)
  if list.class == Array
    list = List.new(list)
    list.each_with_index do |value, index|
      if value.is_a?(Hash)
        list[index] = OpenStackVolumeType.new(value)
      end
    end
  end
  @volume_types = list
end