Class: Pio::OpenFlow13::Apply

Inherits:
Pio::OpenFlow::Instruction show all
Extended by:
Forwardable
Defined in:
lib/pio/open_flow13/apply.rb

Overview

An instruction to apply a list of actions to a packet in-order.

Defined Under Namespace

Classes: Format

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(actions = []) ⇒ Apply

Returns a new instance of Apply.



36
37
38
# File 'lib/pio/open_flow13/apply.rb', line 36

def initialize(actions = [])
  @format = Format.new(actions: actions)
end

Class Method Details

.read(raw_data) ⇒ Object



23
24
25
26
27
# File 'lib/pio/open_flow13/apply.rb', line 23

def self.read(raw_data)
  allocate.tap do |apply|
    apply.instance_variable_set :@format, Format.read(raw_data)
  end
end