Sha256: 6166c1a412e608f015e6d80a7aa66c64a054671899a5812fbc2019c991570de1
Contents?: true
Size: 795 Bytes
Versions: 1
Compression:
Stored size: 795 Bytes
Contents
# frozen_string_literal: true require 'bindata' module Pio module OpenFlow10 module Error class BadRequest < OpenFlow::Message # enum ofp_bad_request_code class BadRequestCode < BinData::Primitive ERROR_CODES = { bad_version: 0, bad_type: 1, bad_stats: 2, bad_vendor: 3, bad_subtype: 4, permissions_error: 5, bad_length: 6, buffer_empty: 7, buffer_unknown: 8 }.freeze endian :big uint16 :error_code def get ERROR_CODES.invert.fetch(error_code) end def set(value) self.error_code = ERROR_CODES.fetch(value) end end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
pio-0.30.2 | lib/pio/open_flow10/error/bad_request/bad_request_code.rb |