Class: Y2Network::ConnectionConfig::Bonding

Inherits:
Base
  • Object
show all
Defined in:
src/lib/y2network/connection_config/bonding.rb

Overview

Configuration for bonding connections

Constant Summary

Constants inherited from Base

Y2Network::ConnectionConfig::Base::PROPOSED_PPPOE_MTU

Instance Attribute Summary collapse

Attributes inherited from Base

#bootproto, #description, #ethtool_options, #firewall_zone, #hostname, #id, #interface, #ip, #ip_aliases, #lladdress, #mtu, #name, #startmode

Instance Method Summary collapse

Methods inherited from Base

#all_ips, #find_master, #propose, #propose_startmode, #type

Constructor Details

#initializeBonding


33
34
35
36
37
# File 'src/lib/y2network/connection_config/bonding.rb', line 33

def initialize
  super()
  @slaves = []
  @options = "mode=active-backup miimon=100"
end

Instance Attribute Details

#optionsString


31
32
33
# File 'src/lib/y2network/connection_config/bonding.rb', line 31

def options
  @options
end

#slavesArray<String>


29
30
31
# File 'src/lib/y2network/connection_config/bonding.rb', line 29

def slaves
  @slaves
end

Instance Method Details

#==(other) ⇒ Object


39
40
41
42
43
# File 'src/lib/y2network/connection_config/bonding.rb', line 39

def ==(other)
  return false unless super

  options == other.options && ((slaves - other.slaves) + (other.slaves - slaves)).empty?
end

#virtual?Boolean


45
46
47
# File 'src/lib/y2network/connection_config/bonding.rb', line 45

def virtual?
  true
end