Class: OvirtSDK4::OpenStackSubnet
- Inherits:
-
Identified
- Object
- Struct
- Identified
- OvirtSDK4::OpenStackSubnet
- Defined in:
- lib/ovirtsdk4/types.rb,
lib/ovirtsdk4/types.rb
Instance Method Summary collapse
-
#==(other) ⇒ Object
Returns
trueifselfandotherhave the same attributes and values. -
#cidr ⇒ String
Returns the value of the
cidrattribute. -
#cidr=(value) ⇒ Object
Sets the value of the
cidrattribute. -
#comment ⇒ String
Returns the value of the
commentattribute. -
#comment=(value) ⇒ Object
Sets the value of the
commentattribute. -
#description ⇒ String
Returns the value of the
descriptionattribute. -
#description=(value) ⇒ Object
Sets the value of the
descriptionattribute. -
#dns_servers ⇒ Array<String>
Returns the value of the
dns_serversattribute. -
#dns_servers=(list) ⇒ Object
Sets the value of the
dns_serversattribute. -
#gateway ⇒ String
Returns the value of the
gatewayattribute. -
#gateway=(value) ⇒ Object
Sets the value of the
gatewayattribute. -
#hash ⇒ Object
Generates a hash value for this object.
-
#id ⇒ String
Returns the value of the
idattribute. -
#id=(value) ⇒ Object
Sets the value of the
idattribute. -
#initialize(opts = {}) ⇒ OpenStackSubnet
constructor
Creates a new instance of the OpenStackSubnet class.
-
#ip_version ⇒ String
Returns the value of the
ip_versionattribute. -
#ip_version=(value) ⇒ Object
Sets the value of the
ip_versionattribute. -
#name ⇒ String
Returns the value of the
nameattribute. -
#name=(value) ⇒ Object
Sets the value of the
nameattribute. -
#openstack_network ⇒ OpenStackNetwork
Returns the value of the
openstack_networkattribute. -
#openstack_network=(value) ⇒ Object
Sets the value of the
openstack_networkattribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ OpenStackSubnet
Creates a new instance of the OvirtSDK4::OpenStackSubnet class.
13181 13182 13183 13184 13185 13186 13187 13188 |
# File 'lib/ovirtsdk4/types.rb', line 13181 def initialize(opts = {}) super(opts) self.cidr = opts[:cidr] self.dns_servers = opts[:dns_servers] self.gateway = opts[:gateway] self.ip_version = opts[:ip_version] self.openstack_network = opts[:openstack_network] end |
Instance Method Details
#==(other) ⇒ Object
Returns true if self and other have the same attributes and values.
13193 13194 13195 13196 13197 13198 13199 13200 |
# File 'lib/ovirtsdk4/types.rb', line 13193 def ==(other) super && @cidr == other.cidr && @dns_servers == other.dns_servers && @gateway == other.gateway && @ip_version == other.ip_version && @openstack_network == other.openstack_network end |
#cidr ⇒ String
Returns the value of the cidr attribute.
12991 12992 12993 |
# File 'lib/ovirtsdk4/types.rb', line 12991 def cidr @cidr end |
#cidr=(value) ⇒ Object
Sets the value of the cidr attribute.
13000 13001 13002 |
# File 'lib/ovirtsdk4/types.rb', line 13000 def cidr=(value) @cidr = value end |
#comment ⇒ String
Returns the value of the comment attribute.
13009 13010 13011 |
# File 'lib/ovirtsdk4/types.rb', line 13009 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment attribute.
13018 13019 13020 |
# File 'lib/ovirtsdk4/types.rb', line 13018 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description attribute.
13027 13028 13029 |
# File 'lib/ovirtsdk4/types.rb', line 13027 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description attribute.
13036 13037 13038 |
# File 'lib/ovirtsdk4/types.rb', line 13036 def description=(value) @description = value end |
#dns_servers ⇒ Array<String>
Returns the value of the dns_servers attribute.
13045 13046 13047 |
# File 'lib/ovirtsdk4/types.rb', line 13045 def dns_servers @dns_servers end |
#dns_servers=(list) ⇒ Object
Sets the value of the dns_servers attribute.
13054 13055 13056 |
# File 'lib/ovirtsdk4/types.rb', line 13054 def dns_servers=(list) @dns_servers = list end |
#gateway ⇒ String
Returns the value of the gateway attribute.
13063 13064 13065 |
# File 'lib/ovirtsdk4/types.rb', line 13063 def gateway @gateway end |
#gateway=(value) ⇒ Object
Sets the value of the gateway attribute.
13072 13073 13074 |
# File 'lib/ovirtsdk4/types.rb', line 13072 def gateway=(value) @gateway = value end |
#hash ⇒ Object
Generates a hash value for this object.
13205 13206 13207 13208 13209 13210 13211 13212 |
# File 'lib/ovirtsdk4/types.rb', line 13205 def hash super + @cidr.hash + @dns_servers.hash + @gateway.hash + @ip_version.hash + @openstack_network.hash end |
#id ⇒ String
Returns the value of the id attribute.
13081 13082 13083 |
# File 'lib/ovirtsdk4/types.rb', line 13081 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id attribute.
13090 13091 13092 |
# File 'lib/ovirtsdk4/types.rb', line 13090 def id=(value) @id = value end |
#ip_version ⇒ String
Returns the value of the ip_version attribute.
13099 13100 13101 |
# File 'lib/ovirtsdk4/types.rb', line 13099 def ip_version @ip_version end |
#ip_version=(value) ⇒ Object
Sets the value of the ip_version attribute.
13108 13109 13110 |
# File 'lib/ovirtsdk4/types.rb', line 13108 def ip_version=(value) @ip_version = value end |
#name ⇒ String
Returns the value of the name attribute.
13117 13118 13119 |
# File 'lib/ovirtsdk4/types.rb', line 13117 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name attribute.
13126 13127 13128 |
# File 'lib/ovirtsdk4/types.rb', line 13126 def name=(value) @name = value end |
#openstack_network ⇒ OpenStackNetwork
Returns the value of the openstack_network attribute.
13135 13136 13137 |
# File 'lib/ovirtsdk4/types.rb', line 13135 def openstack_network @openstack_network end |
#openstack_network=(value) ⇒ Object
Sets the value of the openstack_network attribute.
The value parameter can be an instance of OvirtSDK4::OpenStackNetwork 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.
13148 13149 13150 13151 13152 13153 |
# File 'lib/ovirtsdk4/types.rb', line 13148 def openstack_network=(value) if value.is_a?(Hash) value = OpenStackNetwork.new(value) end @openstack_network = value end |