Class: OvirtSDK4::Image

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

Instance Method Summary (collapse)

Methods included from Type

#href, #href=

Constructor Details

- (Image) initialize(opts = {})

Creates a new instance of the OvirtSDK4::Image 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):

  • :comment (String)

    The value of attribute comment.

  • :description (String)

    The value of attribute description.

  • :id (String)

    The value of attribute id.

  • :name (String)

    The value of attribute name.

  • :storage_domain (StorageDomain, Hash)

    The value of attribute storage_domain.



3830
3831
3832
3833
3834
3835
3836
3837
# File 'lib/ovirtsdk4/types.rb', line 3830

def initialize(opts = {})
  super(opts)
  self.comment = opts[:comment]
  self.description = opts[:description]
  self.id = opts[:id]
  self.name = opts[:name]
  self.storage_domain = opts[:storage_domain]
end

Instance Method Details

- (String) comment

Returns the value of the comment attribute.

Returns:

  • (String)


3720
3721
3722
# File 'lib/ovirtsdk4/types.rb', line 3720

def comment
  return @comment
end

- (Object) comment=(value)

Sets the value of the comment attribute.

Parameters:

  • value (String)


3729
3730
3731
# File 'lib/ovirtsdk4/types.rb', line 3729

def comment=(value)
  @comment = value
end

- (String) description

Returns the value of the description attribute.

Returns:

  • (String)


3738
3739
3740
# File 'lib/ovirtsdk4/types.rb', line 3738

def description
  return @description
end

- (Object) description=(value)

Sets the value of the description attribute.

Parameters:

  • value (String)


3747
3748
3749
# File 'lib/ovirtsdk4/types.rb', line 3747

def description=(value)
  @description = value
end

- (String) id

Returns the value of the id attribute.

Returns:

  • (String)


3756
3757
3758
# File 'lib/ovirtsdk4/types.rb', line 3756

def id
  return @id
end

- (Object) id=(value)

Sets the value of the id attribute.

Parameters:

  • value (String)


3765
3766
3767
# File 'lib/ovirtsdk4/types.rb', line 3765

def id=(value)
  @id = value
end

- (String) name

Returns the value of the name attribute.

Returns:

  • (String)


3774
3775
3776
# File 'lib/ovirtsdk4/types.rb', line 3774

def name
  return @name
end

- (Object) name=(value)

Sets the value of the name attribute.

Parameters:

  • value (String)


3783
3784
3785
# File 'lib/ovirtsdk4/types.rb', line 3783

def name=(value)
  @name = value
end

- (StorageDomain) storage_domain

Returns the value of the storage_domain attribute.

Returns:



3792
3793
3794
# File 'lib/ovirtsdk4/types.rb', line 3792

def storage_domain
  return @storage_domain
end

- (Object) storage_domain=(value)

Sets the value of the storage_domain attribute.

The value parameter can be an instance of StorageDomain 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:



3805
3806
3807
3808
3809
3810
# File 'lib/ovirtsdk4/types.rb', line 3805

def storage_domain=(value)
  if value.is_a?(Hash)
    value = StorageDomain.new(value)
  end
  @storage_domain = value
end