Class: VCloudSdk::NIC
- Inherits:
-
Object
- Object
- VCloudSdk::NIC
- Extended by:
- Forwardable
- Defined in:
- lib/ruby_vcloud_sdk/nic.rb
Instance Attribute Summary collapse
-
#is_primary ⇒ Object
readonly
Returns the value of attribute is_primary.
Instance Method Summary collapse
-
#initialize(entity_xml, is_primary) ⇒ NIC
constructor
A new instance of NIC.
- #is_connected ⇒ Object
- #network_connection_index ⇒ Object (also: #nic_index)
Constructor Details
#initialize(entity_xml, is_primary) ⇒ NIC
Returns a new instance of NIC.
11 12 13 14 |
# File 'lib/ruby_vcloud_sdk/nic.rb', line 11 def initialize(entity_xml, is_primary) @entity_xml = entity_xml @is_primary = is_primary end |
Instance Attribute Details
#is_primary ⇒ Object (readonly)
Returns the value of attribute is_primary.
9 10 11 |
# File 'lib/ruby_vcloud_sdk/nic.rb', line 9 def is_primary @is_primary end |
Instance Method Details
#is_connected ⇒ Object
20 21 22 |
# File 'lib/ruby_vcloud_sdk/nic.rb', line 20 def is_connected @entity_xml.is_connected == "true" end |
#network_connection_index ⇒ Object Also known as: nic_index
16 17 18 |
# File 'lib/ruby_vcloud_sdk/nic.rb', line 16 def network_connection_index @entity_xml.network_connection_index.to_i end |