Refactored nicira extended actions

This commit is contained in:
Eishun Kondoh 2019-03-18 13:31:36 +09:00
parent efd08cf6dd
commit ffcba91395
51 changed files with 1015 additions and 819 deletions

View file

@ -5,17 +5,17 @@ defmodule Openflow.Action.NxExit do
@nxast 17
alias __MODULE__
alias Openflow.Action.Experimenter
def new do
%NxExit{}
end
def to_binary(%NxExit{}) do
exp_body = <<@experimenter::32, @nxast::16, 0::48>>
<<0xFFFF::16, 16::16, exp_body::bytes>>
Experimenter.pack_exp_header(<<@experimenter::32, @nxast::16, 0::48>>)
end
def read(<<@experimenter::32, @nxast::16, 0::48>>) do
def read(<<@experimenter::32, @nxast::16, 0::48, _::bytes>>) do
%NxExit{}
end
end