Class: OvirtSDK4::SpecialObjects
- Defined in:
- lib/ovirtsdk4/types.rb,
lib/ovirtsdk4/types.rb
Instance Method Summary collapse
-
#==(other) ⇒ Object
Returns
true
ifself
andother
have the same attributes and values. -
#blank_template ⇒ Template
Returns the value of the
blank_template
attribute. -
#blank_template=(value) ⇒ Object
Sets the value of the
blank_template
attribute. -
#hash ⇒ Object
Generates a hash value for this object.
-
#initialize(opts = {}) ⇒ SpecialObjects
constructor
Creates a new instance of the SpecialObjects class.
-
#root_tag ⇒ Tag
Returns the value of the
root_tag
attribute. -
#root_tag=(value) ⇒ Object
Sets the value of the
root_tag
attribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ SpecialObjects
Creates a new instance of the OvirtSDK4::SpecialObjects class.
19737 19738 19739 19740 19741 |
# File 'lib/ovirtsdk4/types.rb', line 19737 def initialize(opts = {}) super(opts) self.blank_template = opts[:blank_template] self.root_tag = opts[:root_tag] end |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
19746 19747 19748 19749 19750 |
# File 'lib/ovirtsdk4/types.rb', line 19746 def ==(other) super && @blank_template == other.blank_template && @root_tag == other.root_tag end |
#blank_template ⇒ Template
Returns the value of the blank_template
attribute.
19680 19681 19682 |
# File 'lib/ovirtsdk4/types.rb', line 19680 def blank_template @blank_template end |
#blank_template=(value) ⇒ Object
Sets the value of the blank_template
attribute.
The value
parameter can be an instance of Template 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.
19693 19694 19695 19696 19697 19698 |
# File 'lib/ovirtsdk4/types.rb', line 19693 def blank_template=(value) if value.is_a?(Hash) value = Template.new(value) end @blank_template = value end |
#hash ⇒ Object
Generates a hash value for this object.
19755 19756 19757 19758 19759 |
# File 'lib/ovirtsdk4/types.rb', line 19755 def hash super + @blank_template.hash + @root_tag.hash end |
#root_tag ⇒ Tag
Returns the value of the root_tag
attribute.
19705 19706 19707 |
# File 'lib/ovirtsdk4/types.rb', line 19705 def root_tag @root_tag end |
#root_tag=(value) ⇒ Object
Sets the value of the root_tag
attribute.
The value
parameter can be an instance of Tag 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.
19718 19719 19720 19721 19722 19723 |
# File 'lib/ovirtsdk4/types.rb', line 19718 def root_tag=(value) if value.is_a?(Hash) value = Tag.new(value) end @root_tag = value end |