class Pio::OpenFlow10::SetVlanPriority
An action to modify the VLAN priority of a packet.
Public Class Methods
new(number)
click to toggle source
Calls superclass method
Pio::OpenFlow::Action::new
# File lib/pio/open_flow10/set_vlan_priority.rb, line 14 def initialize(number) priority = number.to_i if priority < 0 || priority > 7 raise ArgumentError, 'VLAN priority must be between 0 and 7 inclusive' end super(vlan_priority: priority) rescue NoMethodError raise TypeError, 'VLAN priority must be an Integer.' end