Class: OvirtSDK4::SystemOptionValue

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

Instance Method Summary collapse

Methods included from Type

#dig, #href, #href=

Constructor Details

#initialize(opts = {}) ⇒ SystemOptionValue

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

  • :value (String)

    The value of attribute value.

  • :version (String)

    The value of attribute version.


22547
22548
22549
22550
22551
# File 'lib/ovirtsdk4/types.rb', line 22547

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

Instance Method Details

#==(other) ⇒ Object

Returns true if self and other have the same attributes and values.


22556
22557
22558
22559
22560
# File 'lib/ovirtsdk4/types.rb', line 22556

def ==(other)
  super &&
  @value == other.value &&
  @version == other.version
end

#hashObject

Generates a hash value for this object.


22565
22566
22567
22568
22569
# File 'lib/ovirtsdk4/types.rb', line 22565

def hash
  super +
  @value.hash +
  @version.hash
end

#valueString

Returns the value of the value attribute.

Returns:

  • (String)

22504
22505
22506
# File 'lib/ovirtsdk4/types.rb', line 22504

def value
  @value
end

#value=(value) ⇒ Object

Sets the value of the value attribute.

Parameters:

  • value (String)

22513
22514
22515
# File 'lib/ovirtsdk4/types.rb', line 22513

def value=(value)
  @value = value
end

#versionString

Returns the value of the version attribute.

Returns:

  • (String)

22522
22523
22524
# File 'lib/ovirtsdk4/types.rb', line 22522

def version
  @version
end

#version=(value) ⇒ Object

Sets the value of the version attribute.

Parameters:

  • value (String)

22531
22532
22533
# File 'lib/ovirtsdk4/types.rb', line 22531

def version=(value)
  @version = value
end