Class: Y2Network::ConnectionConfig::Bridge
- Defined in:
- src/lib/y2network/connection_config/bridge.rb
Overview
Configuration for bridge connections
Constant Summary
Constants inherited from Base
Y2Network::ConnectionConfig::Base::PROPOSED_PPPOE_MTU
Instance Attribute Summary collapse
- #forward_delay ⇒ Integer
- #ports ⇒ Array<String>
-
#stp ⇒ Boolean
Whether spanning tree protocol is enabled or not.
Attributes inherited from Base
#bootproto, #description, #dhclient_set_hostname, #ethtool_options, #firewall_zone, #hostnames, #id, #interface, #ip, #ip_aliases, #lladdress, #mtu, #name, #startmode
Instance Method Summary collapse
- #eql_hash ⇒ Object
-
#initialize ⇒ Bridge
constructor
A new instance of Bridge.
- #virtual? ⇒ Boolean
Methods inherited from Base
#all_ips, #dhcp?, #find_parent, #hostname, #hostname=, #propose, #propose_startmode, #static?, #type
Constructor Details
#initialize ⇒ Bridge
Returns a new instance of Bridge.
37 38 39 40 41 42 |
# File 'src/lib/y2network/connection_config/bridge.rb', line 37 def initialize super() @ports = [] @stp = false @forward_delay = 15 end |
Instance Attribute Details
#forward_delay ⇒ Integer
33 34 35 |
# File 'src/lib/y2network/connection_config/bridge.rb', line 33 def forward_delay @forward_delay end |
#ports ⇒ Array<String>
29 30 31 |
# File 'src/lib/y2network/connection_config/bridge.rb', line 29 def ports @ports end |
#stp ⇒ Boolean
Returns whether spanning tree protocol is enabled or not.
31 32 33 |
# File 'src/lib/y2network/connection_config/bridge.rb', line 31 def stp @stp end |
Instance Method Details
#eql_hash ⇒ Object
44 45 46 47 48 |
# File 'src/lib/y2network/connection_config/bridge.rb', line 44 def eql_hash h = super h[:ports] = h[:ports].sort_by(&:hash) if h.keys.include?(:ports) h end |
#virtual? ⇒ Boolean
50 51 52 |
# File 'src/lib/y2network/connection_config/bridge.rb', line 50 def virtual? true end |