Module: Pio::Type::OpenFlow

Included in:
Echo::Format, Features::Format
Defined in:
lib/pio/type/open_flow.rb

Overview

OpenFlow 1.0 format.

Defined Under Namespace

Classes: PhyPort

Instance Method Summary collapse

Instance Method Details

#openflow_headerObject



9
10
11
12
13
14
15
16
# File 'lib/pio/type/open_flow.rb', line 9

def openflow_header
  class_eval do
    uint8 :version, value: 1
    uint8 :message_type
    uint16 :message_length, initial_value: -> { 8 + body.length }
    uint32 :transaction_id, initial_value: 0
  end
end