Class: OvirtSDK4::ProductInfo

Inherits:
Struct
  • Object
show all
Defined in:
lib/ovirtsdk4/types.rb,
lib/ovirtsdk4/types.rb

Instance Method Summary (collapse)

Methods included from Type

#href, #href=

Constructor Details

- (ProductInfo) initialize(opts = {})

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

  • :name (String)

    The value of attribute name.

  • :vendor (String)

    The value of attribute vendor.

  • :version (Version, Hash)

    The value of attribute version.



10906
10907
10908
10909
10910
10911
# File 'lib/ovirtsdk4/types.rb', line 10906

def initialize(opts = {})
  super(opts)
  self.name = opts[:name]
  self.vendor = opts[:vendor]
  self.version = opts[:version]
end

Instance Method Details

- (String) name

Returns the value of the name attribute.

Returns:

  • (String)


10836
10837
10838
# File 'lib/ovirtsdk4/types.rb', line 10836

def name
  return @name
end

- (Object) name=(value)

Sets the value of the name attribute.

Parameters:

  • value (String)


10845
10846
10847
# File 'lib/ovirtsdk4/types.rb', line 10845

def name=(value)
  @name = value
end

- (String) vendor

Returns the value of the vendor attribute.

Returns:

  • (String)


10854
10855
10856
# File 'lib/ovirtsdk4/types.rb', line 10854

def vendor
  return @vendor
end

- (Object) vendor=(value)

Sets the value of the vendor attribute.

Parameters:

  • value (String)


10863
10864
10865
# File 'lib/ovirtsdk4/types.rb', line 10863

def vendor=(value)
  @vendor = value
end

- (Version) version

Returns the value of the version attribute.

Returns:



10872
10873
10874
# File 'lib/ovirtsdk4/types.rb', line 10872

def version
  return @version
end

- (Object) version=(value)

Sets the value of the version attribute.

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



10885
10886
10887
10888
10889
10890
# File 'lib/ovirtsdk4/types.rb', line 10885

def version=(value)
  if value.is_a?(Hash)
    value = Version.new(value)
  end
  @version = value
end