text: /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_l3_dst_class_id_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30c04); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_l3_dst_class_id of_oxm_bsn_l3_dst_class_id
   */
  
  /**
   * Create a new of_oxm_bsn_l3_dst_class_id object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_l3_dst_class_id
   */
  
  of_object_t *
  of_oxm_bsn_l3_dst_class_id_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_DST_CLASS_ID];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_l3_dst_class_id_init(obj, version, bytes, 0);
      of_oxm_bsn_l3_dst_class_id_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_l3_dst_class_id.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_l3_dst_class_id_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_L3_DST_CLASS_ID] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_DST_CLASS_ID];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_L3_DST_CLASS_ID;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_l3_dst_class_id.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_dst_class_id.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_l3_dst_class_id_value_get(
      of_oxm_bsn_l3_dst_class_id_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_DST_CLASS_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_l3_dst_class_id.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_dst_class_id.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_l3_dst_class_id_value_set(
      of_oxm_bsn_l3_dst_class_id_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_DST_CLASS_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_l3_dst_class_id_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30d08); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_l3_dst_class_id_masked of_oxm_bsn_l3_dst_class_id_masked
   */
  
  /**
   * Create a new of_oxm_bsn_l3_dst_class_id_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_l3_dst_class_id_masked
   */
  
  of_object_t *
  of_oxm_bsn_l3_dst_class_id_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_DST_CLASS_ID_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_l3_dst_class_id_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_l3_dst_class_id_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_l3_dst_class_id_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_l3_dst_class_id_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_L3_DST_CLASS_ID_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_DST_CLASS_ID_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_L3_DST_CLASS_ID_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_l3_dst_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_dst_class_id_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_l3_dst_class_id_masked_value_get(
      of_oxm_bsn_l3_dst_class_id_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_DST_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_l3_dst_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_dst_class_id_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_l3_dst_class_id_masked_value_set(
      of_oxm_bsn_l3_dst_class_id_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_DST_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_l3_dst_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_dst_class_id_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_l3_dst_class_id_masked_value_mask_get(
      of_oxm_bsn_l3_dst_class_id_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_DST_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_l3_dst_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_dst_class_id_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_l3_dst_class_id_masked_value_mask_set(
      of_oxm_bsn_l3_dst_class_id_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_DST_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_l3_interface_class_id_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30804); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_l3_interface_class_id of_oxm_bsn_l3_interface_class_id
   */
  
  /**
   * Create a new of_oxm_bsn_l3_interface_class_id object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_l3_interface_class_id
   */
  
  of_object_t *
  of_oxm_bsn_l3_interface_class_id_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_INTERFACE_CLASS_ID];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_l3_interface_class_id_init(obj, version, bytes, 0);
      of_oxm_bsn_l3_interface_class_id_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_l3_interface_class_id.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_l3_interface_class_id_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_L3_INTERFACE_CLASS_ID] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_INTERFACE_CLASS_ID];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_L3_INTERFACE_CLASS_ID;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_l3_interface_class_id.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_interface_class_id.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_l3_interface_class_id_value_get(
      of_oxm_bsn_l3_interface_class_id_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_INTERFACE_CLASS_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_l3_interface_class_id.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_interface_class_id.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_l3_interface_class_id_value_set(
      of_oxm_bsn_l3_interface_class_id_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_INTERFACE_CLASS_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_l3_interface_class_id_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30908); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_l3_interface_class_id_masked of_oxm_bsn_l3_interface_class_id_masked
   */
  
  /**
   * Create a new of_oxm_bsn_l3_interface_class_id_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_l3_interface_class_id_masked
   */
  
  of_object_t *
  of_oxm_bsn_l3_interface_class_id_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_INTERFACE_CLASS_ID_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_l3_interface_class_id_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_l3_interface_class_id_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_l3_interface_class_id_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_l3_interface_class_id_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_L3_INTERFACE_CLASS_ID_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_INTERFACE_CLASS_ID_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_L3_INTERFACE_CLASS_ID_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_l3_interface_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_interface_class_id_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_l3_interface_class_id_masked_value_get(
      of_oxm_bsn_l3_interface_class_id_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_INTERFACE_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_l3_interface_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_interface_class_id_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_l3_interface_class_id_masked_value_set(
      of_oxm_bsn_l3_interface_class_id_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_INTERFACE_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_l3_interface_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_interface_class_id_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_l3_interface_class_id_masked_value_mask_get(
      of_oxm_bsn_l3_interface_class_id_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_INTERFACE_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_l3_interface_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_interface_class_id_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_l3_interface_class_id_masked_value_mask_set(
      of_oxm_bsn_l3_interface_class_id_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_INTERFACE_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_l3_src_class_id_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30a04); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_l3_src_class_id of_oxm_bsn_l3_src_class_id
   */
  
  /**
   * Create a new of_oxm_bsn_l3_src_class_id object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_l3_src_class_id
   */
  
  of_object_t *
  of_oxm_bsn_l3_src_class_id_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_SRC_CLASS_ID];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_l3_src_class_id_init(obj, version, bytes, 0);
      of_oxm_bsn_l3_src_class_id_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_l3_src_class_id.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_l3_src_class_id_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_L3_SRC_CLASS_ID] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_SRC_CLASS_ID];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_L3_SRC_CLASS_ID;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_l3_src_class_id.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_src_class_id.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_l3_src_class_id_value_get(
      of_oxm_bsn_l3_src_class_id_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_SRC_CLASS_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_l3_src_class_id.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_src_class_id.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_l3_src_class_id_value_set(
      of_oxm_bsn_l3_src_class_id_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_SRC_CLASS_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_l3_src_class_id_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30b08); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_l3_src_class_id_masked of_oxm_bsn_l3_src_class_id_masked
   */
  
  /**
   * Create a new of_oxm_bsn_l3_src_class_id_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_l3_src_class_id_masked
   */
  
  of_object_t *
  of_oxm_bsn_l3_src_class_id_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_SRC_CLASS_ID_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_l3_src_class_id_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_l3_src_class_id_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_l3_src_class_id_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_l3_src_class_id_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_L3_SRC_CLASS_ID_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_L3_SRC_CLASS_ID_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_L3_SRC_CLASS_ID_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_l3_src_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_src_class_id_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_l3_src_class_id_masked_value_get(
      of_oxm_bsn_l3_src_class_id_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_SRC_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_l3_src_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_src_class_id_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_l3_src_class_id_masked_value_set(
      of_oxm_bsn_l3_src_class_id_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_SRC_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_l3_src_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_src_class_id_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_l3_src_class_id_masked_value_mask_get(
      of_oxm_bsn_l3_src_class_id_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_SRC_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_l3_src_class_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_l3_src_class_id_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_l3_src_class_id_masked_value_mask_set(
      of_oxm_bsn_l3_src_class_id_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_L3_SRC_CLASS_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_lag_id_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30204); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_lag_id of_oxm_bsn_lag_id
   */
  
  /**
   * Create a new of_oxm_bsn_lag_id object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_lag_id
   */
  
  of_object_t *
  of_oxm_bsn_lag_id_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_LAG_ID];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_lag_id_init(obj, version, bytes, 0);
      of_oxm_bsn_lag_id_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_lag_id.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_lag_id_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_LAG_ID] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_LAG_ID];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_LAG_ID;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_lag_id.
   * @param obj Pointer to an object of type of_oxm_bsn_lag_id.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_lag_id_value_get(
      of_oxm_bsn_lag_id_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_LAG_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_lag_id.
   * @param obj Pointer to an object of type of_oxm_bsn_lag_id.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_lag_id_value_set(
      of_oxm_bsn_lag_id_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_LAG_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_lag_id_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30308); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_lag_id_masked of_oxm_bsn_lag_id_masked
   */
  
  /**
   * Create a new of_oxm_bsn_lag_id_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_lag_id_masked
   */
  
  of_object_t *
  of_oxm_bsn_lag_id_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_LAG_ID_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_lag_id_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_lag_id_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_lag_id_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_lag_id_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_LAG_ID_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_LAG_ID_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_LAG_ID_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_lag_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_lag_id_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_lag_id_masked_value_get(
      of_oxm_bsn_lag_id_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_LAG_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_lag_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_lag_id_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_lag_id_masked_value_set(
      of_oxm_bsn_lag_id_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_LAG_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_lag_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_lag_id_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_lag_id_masked_value_mask_get(
      of_oxm_bsn_lag_id_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_LAG_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_lag_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_lag_id_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_lag_id_masked_value_mask_set(
      of_oxm_bsn_lag_id_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_LAG_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_tcp_flags_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x32002); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_tcp_flags of_oxm_bsn_tcp_flags
   */
  
  /**
   * Create a new of_oxm_bsn_tcp_flags object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_tcp_flags
   */
  
  of_object_t *
  of_oxm_bsn_tcp_flags_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_TCP_FLAGS];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_tcp_flags_init(obj, version, bytes, 0);
      of_oxm_bsn_tcp_flags_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_tcp_flags.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_tcp_flags_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_TCP_FLAGS] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_TCP_FLAGS];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_TCP_FLAGS;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_tcp_flags.
   * @param obj Pointer to an object of type of_oxm_bsn_tcp_flags.
   * @param value Pointer to the child object of type
   * uint16_t to be filled out.
   *
   */
  void
  of_oxm_bsn_tcp_flags_value_get(
      of_oxm_bsn_tcp_flags_t *obj,
      uint16_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_TCP_FLAGS);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u16_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_tcp_flags.
   * @param obj Pointer to an object of type of_oxm_bsn_tcp_flags.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_tcp_flags_value_set(
      of_oxm_bsn_tcp_flags_t *obj,
      uint16_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_TCP_FLAGS);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u16_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_tcp_flags_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x32104); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_tcp_flags_masked of_oxm_bsn_tcp_flags_masked
   */
  
  /**
   * Create a new of_oxm_bsn_tcp_flags_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_tcp_flags_masked
   */
  
  of_object_t *
  of_oxm_bsn_tcp_flags_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_TCP_FLAGS_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_tcp_flags_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_tcp_flags_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_tcp_flags_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_tcp_flags_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_TCP_FLAGS_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_TCP_FLAGS_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_TCP_FLAGS_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_tcp_flags_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_tcp_flags_masked.
   * @param value Pointer to the child object of type
   * uint16_t to be filled out.
   *
   */
  void
  of_oxm_bsn_tcp_flags_masked_value_get(
      of_oxm_bsn_tcp_flags_masked_t *obj,
      uint16_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_TCP_FLAGS_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u16_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_tcp_flags_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_tcp_flags_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_tcp_flags_masked_value_set(
      of_oxm_bsn_tcp_flags_masked_t *obj,
      uint16_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_TCP_FLAGS_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u16_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_tcp_flags_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_tcp_flags_masked.
   * @param value_mask Pointer to the child object of type
   * uint16_t to be filled out.
   *
   */
  void
  of_oxm_bsn_tcp_flags_masked_value_mask_get(
      of_oxm_bsn_tcp_flags_masked_t *obj,
      uint16_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_TCP_FLAGS_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 6;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u16_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_tcp_flags_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_tcp_flags_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_tcp_flags_masked_value_mask_set(
      of_oxm_bsn_tcp_flags_masked_t *obj,
      uint16_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_TCP_FLAGS_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 6;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u16_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf0_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31004); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf0 of_oxm_bsn_udf0
   */
  
  /**
   * Create a new of_oxm_bsn_udf0 object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf0
   */
  
  of_object_t *
  of_oxm_bsn_udf0_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF0];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf0_init(obj, version, bytes, 0);
      of_oxm_bsn_udf0_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf0.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf0_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF0] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF0];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF0;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf0.
   * @param obj Pointer to an object of type of_oxm_bsn_udf0.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf0_value_get(
      of_oxm_bsn_udf0_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF0);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf0.
   * @param obj Pointer to an object of type of_oxm_bsn_udf0.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf0_value_set(
      of_oxm_bsn_udf0_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF0);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf0_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31108); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf0_masked of_oxm_bsn_udf0_masked
   */
  
  /**
   * Create a new of_oxm_bsn_udf0_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf0_masked
   */
  
  of_object_t *
  of_oxm_bsn_udf0_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF0_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf0_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_udf0_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf0_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf0_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF0_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF0_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF0_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf0_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf0_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf0_masked_value_get(
      of_oxm_bsn_udf0_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF0_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf0_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf0_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf0_masked_value_set(
      of_oxm_bsn_udf0_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF0_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_udf0_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf0_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf0_masked_value_mask_get(
      of_oxm_bsn_udf0_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF0_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_udf0_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf0_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_udf0_masked_value_mask_set(
      of_oxm_bsn_udf0_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF0_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf1_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31204); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf1 of_oxm_bsn_udf1
   */
  
  /**
   * Create a new of_oxm_bsn_udf1 object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf1
   */
  
  of_object_t *
  of_oxm_bsn_udf1_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF1];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf1_init(obj, version, bytes, 0);
      of_oxm_bsn_udf1_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf1.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf1_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF1] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF1];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF1;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf1.
   * @param obj Pointer to an object of type of_oxm_bsn_udf1.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf1_value_get(
      of_oxm_bsn_udf1_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF1);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf1.
   * @param obj Pointer to an object of type of_oxm_bsn_udf1.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf1_value_set(
      of_oxm_bsn_udf1_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF1);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf1_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31308); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf1_masked of_oxm_bsn_udf1_masked
   */
  
  /**
   * Create a new of_oxm_bsn_udf1_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf1_masked
   */
  
  of_object_t *
  of_oxm_bsn_udf1_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF1_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf1_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_udf1_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf1_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf1_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF1_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF1_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF1_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf1_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf1_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf1_masked_value_get(
      of_oxm_bsn_udf1_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF1_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf1_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf1_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf1_masked_value_set(
      of_oxm_bsn_udf1_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF1_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_udf1_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf1_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf1_masked_value_mask_get(
      of_oxm_bsn_udf1_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF1_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_udf1_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf1_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_udf1_masked_value_mask_set(
      of_oxm_bsn_udf1_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF1_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf2_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31404); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf2 of_oxm_bsn_udf2
   */
  
  /**
   * Create a new of_oxm_bsn_udf2 object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf2
   */
  
  of_object_t *
  of_oxm_bsn_udf2_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF2];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf2_init(obj, version, bytes, 0);
      of_oxm_bsn_udf2_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf2.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf2_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF2] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF2];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF2;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf2.
   * @param obj Pointer to an object of type of_oxm_bsn_udf2.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf2_value_get(
      of_oxm_bsn_udf2_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF2);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf2.
   * @param obj Pointer to an object of type of_oxm_bsn_udf2.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf2_value_set(
      of_oxm_bsn_udf2_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF2);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf2_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31508); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf2_masked of_oxm_bsn_udf2_masked
   */
  
  /**
   * Create a new of_oxm_bsn_udf2_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf2_masked
   */
  
  of_object_t *
  of_oxm_bsn_udf2_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF2_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf2_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_udf2_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf2_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf2_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF2_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF2_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF2_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf2_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf2_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf2_masked_value_get(
      of_oxm_bsn_udf2_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF2_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf2_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf2_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf2_masked_value_set(
      of_oxm_bsn_udf2_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF2_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_udf2_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf2_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf2_masked_value_mask_get(
      of_oxm_bsn_udf2_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF2_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_udf2_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf2_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_udf2_masked_value_mask_set(
      of_oxm_bsn_udf2_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF2_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf3_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31604); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf3 of_oxm_bsn_udf3
   */
  
  /**
   * Create a new of_oxm_bsn_udf3 object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf3
   */
  
  of_object_t *
  of_oxm_bsn_udf3_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF3];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf3_init(obj, version, bytes, 0);
      of_oxm_bsn_udf3_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf3.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf3_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF3] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF3];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF3;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf3.
   * @param obj Pointer to an object of type of_oxm_bsn_udf3.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf3_value_get(
      of_oxm_bsn_udf3_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF3);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf3.
   * @param obj Pointer to an object of type of_oxm_bsn_udf3.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf3_value_set(
      of_oxm_bsn_udf3_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF3);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf3_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31708); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf3_masked of_oxm_bsn_udf3_masked
   */
  
  /**
   * Create a new of_oxm_bsn_udf3_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf3_masked
   */
  
  of_object_t *
  of_oxm_bsn_udf3_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF3_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf3_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_udf3_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf3_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf3_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF3_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF3_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF3_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf3_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf3_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf3_masked_value_get(
      of_oxm_bsn_udf3_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF3_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf3_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf3_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf3_masked_value_set(
      of_oxm_bsn_udf3_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF3_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_udf3_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf3_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf3_masked_value_mask_get(
      of_oxm_bsn_udf3_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF3_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_udf3_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf3_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_udf3_masked_value_mask_set(
      of_oxm_bsn_udf3_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF3_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf4_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31804); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf4 of_oxm_bsn_udf4
   */
  
  /**
   * Create a new of_oxm_bsn_udf4 object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf4
   */
  
  of_object_t *
  of_oxm_bsn_udf4_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF4];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf4_init(obj, version, bytes, 0);
      of_oxm_bsn_udf4_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf4.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf4_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF4] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF4];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF4;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf4.
   * @param obj Pointer to an object of type of_oxm_bsn_udf4.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf4_value_get(
      of_oxm_bsn_udf4_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF4);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf4.
   * @param obj Pointer to an object of type of_oxm_bsn_udf4.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf4_value_set(
      of_oxm_bsn_udf4_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF4);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf4_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31908); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf4_masked of_oxm_bsn_udf4_masked
   */
  
  /**
   * Create a new of_oxm_bsn_udf4_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf4_masked
   */
  
  of_object_t *
  of_oxm_bsn_udf4_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF4_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf4_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_udf4_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf4_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf4_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF4_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF4_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF4_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf4_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf4_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf4_masked_value_get(
      of_oxm_bsn_udf4_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF4_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf4_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf4_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf4_masked_value_set(
      of_oxm_bsn_udf4_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF4_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_udf4_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf4_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf4_masked_value_mask_get(
      of_oxm_bsn_udf4_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF4_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_udf4_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf4_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_udf4_masked_value_mask_set(
      of_oxm_bsn_udf4_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF4_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf5_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31a04); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf5 of_oxm_bsn_udf5
   */
  
  /**
   * Create a new of_oxm_bsn_udf5 object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf5
   */
  
  of_object_t *
  of_oxm_bsn_udf5_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF5];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf5_init(obj, version, bytes, 0);
      of_oxm_bsn_udf5_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf5.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf5_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF5] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF5];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF5;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf5.
   * @param obj Pointer to an object of type of_oxm_bsn_udf5.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf5_value_get(
      of_oxm_bsn_udf5_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF5);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf5.
   * @param obj Pointer to an object of type of_oxm_bsn_udf5.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf5_value_set(
      of_oxm_bsn_udf5_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF5);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf5_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31b08); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf5_masked of_oxm_bsn_udf5_masked
   */
  
  /**
   * Create a new of_oxm_bsn_udf5_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf5_masked
   */
  
  of_object_t *
  of_oxm_bsn_udf5_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF5_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf5_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_udf5_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf5_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf5_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF5_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF5_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF5_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf5_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf5_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf5_masked_value_get(
      of_oxm_bsn_udf5_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF5_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf5_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf5_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf5_masked_value_set(
      of_oxm_bsn_udf5_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF5_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_udf5_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf5_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf5_masked_value_mask_get(
      of_oxm_bsn_udf5_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF5_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_udf5_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf5_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_udf5_masked_value_mask_set(
      of_oxm_bsn_udf5_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF5_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf6_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31c04); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf6 of_oxm_bsn_udf6
   */
  
  /**
   * Create a new of_oxm_bsn_udf6 object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf6
   */
  
  of_object_t *
  of_oxm_bsn_udf6_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF6];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf6_init(obj, version, bytes, 0);
      of_oxm_bsn_udf6_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf6.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf6_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF6] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF6];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF6;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf6.
   * @param obj Pointer to an object of type of_oxm_bsn_udf6.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf6_value_get(
      of_oxm_bsn_udf6_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF6);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf6.
   * @param obj Pointer to an object of type of_oxm_bsn_udf6.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf6_value_set(
      of_oxm_bsn_udf6_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF6);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf6_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31d08); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf6_masked of_oxm_bsn_udf6_masked
   */
  
  /**
   * Create a new of_oxm_bsn_udf6_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf6_masked
   */
  
  of_object_t *
  of_oxm_bsn_udf6_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF6_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf6_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_udf6_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf6_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf6_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF6_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF6_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF6_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf6_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf6_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf6_masked_value_get(
      of_oxm_bsn_udf6_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF6_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf6_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf6_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf6_masked_value_set(
      of_oxm_bsn_udf6_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF6_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_udf6_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf6_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf6_masked_value_mask_get(
      of_oxm_bsn_udf6_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF6_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_udf6_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf6_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_udf6_masked_value_mask_set(
      of_oxm_bsn_udf6_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF6_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf7_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31e04); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf7 of_oxm_bsn_udf7
   */
  
  /**
   * Create a new of_oxm_bsn_udf7 object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf7
   */
  
  of_object_t *
  of_oxm_bsn_udf7_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF7];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf7_init(obj, version, bytes, 0);
      of_oxm_bsn_udf7_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf7.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf7_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF7] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF7];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF7;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf7.
   * @param obj Pointer to an object of type of_oxm_bsn_udf7.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf7_value_get(
      of_oxm_bsn_udf7_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF7);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf7.
   * @param obj Pointer to an object of type of_oxm_bsn_udf7.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf7_value_set(
      of_oxm_bsn_udf7_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF7);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_udf7_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x31f08); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_udf7_masked of_oxm_bsn_udf7_masked
   */
  
  /**
   * Create a new of_oxm_bsn_udf7_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_udf7_masked
   */
  
  of_object_t *
  of_oxm_bsn_udf7_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF7_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_udf7_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_udf7_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_udf7_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_udf7_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_UDF7_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_UDF7_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_UDF7_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_udf7_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf7_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf7_masked_value_get(
      of_oxm_bsn_udf7_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF7_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_udf7_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf7_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_udf7_masked_value_set(
      of_oxm_bsn_udf7_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF7_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_udf7_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf7_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_udf7_masked_value_mask_get(
      of_oxm_bsn_udf7_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF7_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_udf7_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_udf7_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_udf7_masked_value_mask_set(
      of_oxm_bsn_udf7_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_UDF7_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_vlan_xlate_port_group_id_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x32204); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_vlan_xlate_port_group_id of_oxm_bsn_vlan_xlate_port_group_id
   */
  
  /**
   * Create a new of_oxm_bsn_vlan_xlate_port_group_id object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_vlan_xlate_port_group_id
   */
  
  of_object_t *
  of_oxm_bsn_vlan_xlate_port_group_id_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_vlan_xlate_port_group_id_init(obj, version, bytes, 0);
      of_oxm_bsn_vlan_xlate_port_group_id_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_vlan_xlate_port_group_id.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_vlan_xlate_port_group_id_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_vlan_xlate_port_group_id.
   * @param obj Pointer to an object of type of_oxm_bsn_vlan_xlate_port_group_id.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_vlan_xlate_port_group_id_value_get(
      of_oxm_bsn_vlan_xlate_port_group_id_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_vlan_xlate_port_group_id.
   * @param obj Pointer to an object of type of_oxm_bsn_vlan_xlate_port_group_id.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_vlan_xlate_port_group_id_value_set(
      of_oxm_bsn_vlan_xlate_port_group_id_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_vlan_xlate_port_group_id_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x32308); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_vlan_xlate_port_group_id_masked of_oxm_bsn_vlan_xlate_port_group_id_masked
   */
  
  /**
   * Create a new of_oxm_bsn_vlan_xlate_port_group_id_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_vlan_xlate_port_group_id_masked
   */
  
  of_object_t *
  of_oxm_bsn_vlan_xlate_port_group_id_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_vlan_xlate_port_group_id_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_vlan_xlate_port_group_id_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_vlan_xlate_port_group_id_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_vlan_xlate_port_group_id_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_vlan_xlate_port_group_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_vlan_xlate_port_group_id_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_vlan_xlate_port_group_id_masked_value_get(
      of_oxm_bsn_vlan_xlate_port_group_id_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_vlan_xlate_port_group_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_vlan_xlate_port_group_id_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_vlan_xlate_port_group_id_masked_value_set(
      of_oxm_bsn_vlan_xlate_port_group_id_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_vlan_xlate_port_group_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_vlan_xlate_port_group_id_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_vlan_xlate_port_group_id_masked_value_mask_get(
      of_oxm_bsn_vlan_xlate_port_group_id_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_vlan_xlate_port_group_id_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_vlan_xlate_port_group_id_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_vlan_xlate_port_group_id_masked_value_mask_set(
      of_oxm_bsn_vlan_xlate_port_group_id_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VLAN_XLATE_PORT_GROUP_ID_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_vrf_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30404); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_vrf of_oxm_bsn_vrf
   */
  
  /**
   * Create a new of_oxm_bsn_vrf object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_vrf
   */
  
  of_object_t *
  of_oxm_bsn_vrf_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_VRF];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_vrf_init(obj, version, bytes, 0);
      of_oxm_bsn_vrf_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_vrf.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_vrf_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_VRF] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_VRF];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_VRF;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_vrf.
   * @param obj Pointer to an object of type of_oxm_bsn_vrf.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_vrf_value_get(
      of_oxm_bsn_vrf_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VRF);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_vrf.
   * @param obj Pointer to an object of type of_oxm_bsn_vrf.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_vrf_value_set(
      of_oxm_bsn_vrf_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VRF);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_bsn_vrf_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x30508); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_bsn_vrf_masked of_oxm_bsn_vrf_masked
   */
  
  /**
   * Create a new of_oxm_bsn_vrf_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_bsn_vrf_masked
   */
  
  of_object_t *
  of_oxm_bsn_vrf_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_BSN_VRF_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_bsn_vrf_masked_init(obj, version, bytes, 0);
      of_oxm_bsn_vrf_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_bsn_vrf_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_bsn_vrf_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_BSN_VRF_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_BSN_VRF_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_BSN_VRF_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_bsn_vrf_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_vrf_masked.
   * @param value Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_vrf_masked_value_get(
      of_oxm_bsn_vrf_masked_t *obj,
      uint32_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VRF_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_bsn_vrf_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_vrf_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_bsn_vrf_masked_value_set(
      of_oxm_bsn_vrf_masked_t *obj,
      uint32_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VRF_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_bsn_vrf_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_vrf_masked.
   * @param value_mask Pointer to the child object of type
   * uint32_t to be filled out.
   *
   */
  void
  of_oxm_bsn_vrf_masked_value_mask_get(
      of_oxm_bsn_vrf_masked_t *obj,
      uint32_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VRF_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_bsn_vrf_masked.
   * @param obj Pointer to an object of type of_oxm_bsn_vrf_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_bsn_vrf_masked_value_mask_set(
      of_oxm_bsn_vrf_masked_t *obj,
      uint32_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_BSN_VRF_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 8;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_u32_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_conn_tracking_ipv6_dst_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x1f610); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_conn_tracking_ipv6_dst of_oxm_conn_tracking_ipv6_dst
   */
  
  /**
   * Create a new of_oxm_conn_tracking_ipv6_dst object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_conn_tracking_ipv6_dst
   */
  
  of_object_t *
  of_oxm_conn_tracking_ipv6_dst_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_CONN_TRACKING_IPV6_DST];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_conn_tracking_ipv6_dst_init(obj, version, bytes, 0);
      of_oxm_conn_tracking_ipv6_dst_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_conn_tracking_ipv6_dst.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_conn_tracking_ipv6_dst_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_CONN_TRACKING_IPV6_DST] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_CONN_TRACKING_IPV6_DST];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_CONN_TRACKING_IPV6_DST;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_conn_tracking_ipv6_dst.
   * @param obj Pointer to an object of type of_oxm_conn_tracking_ipv6_dst.
   * @param value Pointer to the child object of type
   * of_ipv6_t to be filled out.
   *
   */
  void
  of_oxm_conn_tracking_ipv6_dst_value_get(
      of_oxm_conn_tracking_ipv6_dst_t *obj,
      of_ipv6_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_CONN_TRACKING_IPV6_DST);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_ipv6_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_conn_tracking_ipv6_dst.
   * @param obj Pointer to an object of type of_oxm_conn_tracking_ipv6_dst.
   * @param value The value to write into the object
   */
  void
  of_oxm_conn_tracking_ipv6_dst_value_set(
      of_oxm_conn_tracking_ipv6_dst_t *obj,
      of_ipv6_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_CONN_TRACKING_IPV6_DST);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_ipv6_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  /* Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University */
  /* Copyright (c) 2011, 2012 Open Networking Foundation */
  /* Copyright (c) 2012, 2013 Big Switch Networks, Inc. */
  /* See the file LICENSE.loci which should have been included in the source distribution */
  #ifdef __GNUC__
  
  #ifdef __linux__
  /* glibc */
  #include <features.h>
  #else
  /* NetBSD etc */
  #include <sys/cdefs.h>
  #ifdef __GNUC_PREREQ__
  #define __GNUC_PREREQ __GNUC_PREREQ__
  #endif
  #endif
  
  #ifndef __GNUC_PREREQ
  /* fallback */
  #define __GNUC_PREREQ(maj, min) 0
  #endif
  
  #if __GNUC_PREREQ(4,6)
  #pragma GCC diagnostic ignored "-Wunused-but-set-variable"
  #endif
  
  #endif
  
  #include "loci_log.h"
  #include "loci_int.h"
  
  void
  of_oxm_conn_tracking_ipv6_dst_masked_push_wire_types(of_object_t *obj)
  {
      unsigned char *buf = OF_OBJECT_BUFFER_INDEX(obj, 0);
      switch (obj->version) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          *(uint32_t *)(buf + 0) = U32_HTON(0x1f720); /* type_len */
          break;
      default:
          UNREACHABLE();
      }
  }
  
  
  
  /**
   * \defgroup of_oxm_conn_tracking_ipv6_dst_masked of_oxm_conn_tracking_ipv6_dst_masked
   */
  
  /**
   * Create a new of_oxm_conn_tracking_ipv6_dst_masked object
   *
   * @param version The wire version to use for the object
   * @return Pointer to the newly create object or NULL on error
   *
   * Initializes the new object with it's default fixed length associating
   * a new underlying wire buffer.
   *
   * \ingroup of_oxm_conn_tracking_ipv6_dst_masked
   */
  
  of_object_t *
  of_oxm_conn_tracking_ipv6_dst_masked_new(of_version_t version)
  {
      of_object_t *obj;
      int bytes;
  
      bytes = of_object_fixed_len[version][OF_OXM_CONN_TRACKING_IPV6_DST_MASKED];
  
      if ((obj = of_object_new(bytes)) == NULL) {
          return NULL;
      }
  
      of_oxm_conn_tracking_ipv6_dst_masked_init(obj, version, bytes, 0);
      of_oxm_conn_tracking_ipv6_dst_masked_push_wire_types(obj);
  
      return obj;
  }
  
  /**
   * Initialize an object of type of_oxm_conn_tracking_ipv6_dst_masked.
   *
   * @param obj Pointer to the object to initialize
   * @param version The wire version to use for the object
   * @param bytes How many bytes in the object
   * @param clean_wire Boolean: If true, clear the wire object control struct
   *
   * If bytes < 0, then the default fixed length is used for the object
   *
   * This is a "coerce" function that sets up the pointers for the
   * accessors properly.
   *
   * If anything other than 0 is passed in for the buffer size, the underlying
   * wire buffer will have 'grow' called.
   */
  
  void
  of_oxm_conn_tracking_ipv6_dst_masked_init(of_object_t *obj,
      of_version_t version, int bytes, int clean_wire)
  {
      LOCI_ASSERT(of_object_fixed_len[version][OF_OXM_CONN_TRACKING_IPV6_DST_MASKED] >= 0);
      if (clean_wire) {
          MEMSET(obj, 0, sizeof(*obj));
      }
      if (bytes < 0) {
          bytes = of_object_fixed_len[version][OF_OXM_CONN_TRACKING_IPV6_DST_MASKED];
      }
      obj->version = version;
      obj->length = bytes;
      obj->object_id = OF_OXM_CONN_TRACKING_IPV6_DST_MASKED;
  
      /* Grow the wire buffer */
      if (obj->wbuf != NULL) {
          int tot_bytes;
  
          tot_bytes = bytes + obj->obj_offset;
          of_wire_buffer_grow(obj->wbuf, tot_bytes);
      }
  }
  
  /**
   * Get value from an object of type of_oxm_conn_tracking_ipv6_dst_masked.
   * @param obj Pointer to an object of type of_oxm_conn_tracking_ipv6_dst_masked.
   * @param value Pointer to the child object of type
   * of_ipv6_t to be filled out.
   *
   */
  void
  of_oxm_conn_tracking_ipv6_dst_masked_value_get(
      of_oxm_conn_tracking_ipv6_dst_masked_t *obj,
      of_ipv6_t *value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_CONN_TRACKING_IPV6_DST_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_ipv6_get(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value in an object of type of_oxm_conn_tracking_ipv6_dst_masked.
   * @param obj Pointer to an object of type of_oxm_conn_tracking_ipv6_dst_masked.
   * @param value The value to write into the object
   */
  void
  of_oxm_conn_tracking_ipv6_dst_masked_value_set(
      of_oxm_conn_tracking_ipv6_dst_masked_t *obj,
      of_ipv6_t value)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_CONN_TRACKING_IPV6_DST_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 4;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_ipv6_set(wbuf, abs_offset, value);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Get value_mask from an object of type of_oxm_conn_tracking_ipv6_dst_masked.
   * @param obj Pointer to an object of type of_oxm_conn_tracking_ipv6_dst_masked.
   * @param value_mask Pointer to the child object of type
   * of_ipv6_t to be filled out.
   *
   */
  void
  of_oxm_conn_tracking_ipv6_dst_masked_value_mask_get(
      of_oxm_conn_tracking_ipv6_dst_masked_t *obj,
      of_ipv6_t *value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_CONN_TRACKING_IPV6_DST_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 20;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_ipv6_get(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  
  /**
   * Set value_mask in an object of type of_oxm_conn_tracking_ipv6_dst_masked.
   * @param obj Pointer to an object of type of_oxm_conn_tracking_ipv6_dst_masked.
   * @param value_mask The value to write into the object
   */
  void
  of_oxm_conn_tracking_ipv6_dst_masked_value_mask_set(
      of_oxm_conn_tracking_ipv6_dst_masked_t *obj,
      of_ipv6_t value_mask)
  {
      of_wire_buffer_t *wbuf;
      int offset = 0; /* Offset of value relative to the start obj */
      int abs_offset; /* Offset of value relative to start of wbuf */
      of_version_t ver;
  
      LOCI_ASSERT(obj->object_id == OF_OXM_CONN_TRACKING_IPV6_DST_MASKED);
      ver = obj->version;
      wbuf = OF_OBJECT_TO_WBUF(obj);
      LOCI_ASSERT(wbuf != NULL);
  
      /* By version, determine offset and current length (where needed) */
      switch (ver) {
      case OF_VERSION_1_2:
      case OF_VERSION_1_3:
      case OF_VERSION_1_4:
          offset = 20;
          break;
      default:
          LOCI_ASSERT(0);
      }
  
      abs_offset = OF_OBJECT_ABSOLUTE_OFFSET(obj, offset);
      LOCI_ASSERT(abs_offset >= 0);
      of_wire_buffer_ipv6_set(wbuf, abs_offset, value_mask);
  
      OF_LENGTH_CHECK_ASSERT(obj);
  
      return ;
  }
  