/* Generated by the protocol buffer compiler.  DO NOT EDIT! */
/* Generated from: netdev.proto */

#ifndef PROTOBUF_C_netdev_2eproto__INCLUDED
#define PROTOBUF_C_netdev_2eproto__INCLUDED

#include <protobuf-c/protobuf-c.h>

PROTOBUF_C__BEGIN_DECLS

#if PROTOBUF_C_VERSION_NUMBER < 1003000
# error This file was generated by a newer version of protobuf-c which is incompatible with your libprotobuf-c headers. Please update your headers.
#elif 1005002 < PROTOBUF_C_MIN_COMPILER_VERSION
# error This file was generated by an older version of protobuf-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protobuf-c.
#endif

#include "macvlan.pb-c.h"
#include "opts.pb-c.h"
#include "tun.pb-c.h"
#include "sysctl.pb-c.h"
#include "sit.pb-c.h"

typedef struct NetDeviceEntry NetDeviceEntry;
typedef struct NetnsId NetnsId;
typedef struct NetnsEntry NetnsEntry;


/* --- enums --- */

typedef enum _NdType {
  ND_TYPE__LOOPBACK = 1,
  ND_TYPE__VETH = 2,
  ND_TYPE__TUN = 3,
  /*
   * External link -- for those CRIU only dumps and restores
   * link parameters such as flags, address, MTU, etc. The
   * existence of the link on restore should be provided
   * by the setup-namespaces script.
   */
  ND_TYPE__EXTLINK = 4,
  /*
   * OpenVZ device 
   */
  ND_TYPE__VENET = 5,
  ND_TYPE__BRIDGE = 6,
  ND_TYPE__MACVLAN = 7,
  ND_TYPE__SIT = 8
    PROTOBUF_C__FORCE_ENUM_TO_BE_INT_SIZE(ND_TYPE)
} NdType;

/* --- messages --- */

struct  NetDeviceEntry
{
  ProtobufCMessage base;
  NdType type;
  uint32_t ifindex;
  uint32_t mtu;
  uint32_t flags;
  char *name;
  TunLinkEntry *tun;
  protobuf_c_boolean has_address;
  ProtobufCBinaryData address;
  size_t n_conf;
  int32_t *conf;
  size_t n_conf4;
  SysctlEntry **conf4;
  size_t n_conf6;
  SysctlEntry **conf6;
  MacvlanLinkEntry *macvlan;
  protobuf_c_boolean has_peer_ifindex;
  uint32_t peer_ifindex;
  protobuf_c_boolean has_peer_nsid;
  uint32_t peer_nsid;
  protobuf_c_boolean has_master;
  uint32_t master;
  SitEntry *sit;
};
#define NET_DEVICE_ENTRY__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&net_device_entry__descriptor) \
, ND_TYPE__LOOPBACK, 0, 0, 0, NULL, NULL, 0, {0,NULL}, 0,NULL, 0,NULL, 0,NULL, NULL, 0, 0, 0, 0, 0, 0, NULL }


struct  NetnsId
{
  ProtobufCMessage base;
  /*
   * This is CRIU's id which is allocated for each namespace 
   */
  uint32_t target_ns_id;
  /*
   * This is an id which can be used to address this namespace
   * from another network namespace. Each network namespace has
   * one set of id-s for other namespaces.
   */
  int32_t netnsid_value;
};
#define NETNS_ID__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&netns_id__descriptor) \
, 0, 0 }


struct  NetnsEntry
{
  ProtobufCMessage base;
  size_t n_def_conf;
  int32_t *def_conf;
  size_t n_all_conf;
  int32_t *all_conf;
  size_t n_def_conf4;
  SysctlEntry **def_conf4;
  size_t n_all_conf4;
  SysctlEntry **all_conf4;
  size_t n_def_conf6;
  SysctlEntry **def_conf6;
  size_t n_all_conf6;
  SysctlEntry **all_conf6;
  size_t n_nsids;
  NetnsId **nsids;
  char *ext_key;
  size_t n_unix_conf;
  SysctlEntry **unix_conf;
  size_t n_ipv4_sysctl;
  SysctlEntry **ipv4_sysctl;
};
#define NETNS_ENTRY__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&netns_entry__descriptor) \
, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, NULL, 0,NULL, 0,NULL }


/* NetDeviceEntry methods */
void   net_device_entry__init
                     (NetDeviceEntry         *message);
size_t net_device_entry__get_packed_size
                     (const NetDeviceEntry   *message);
size_t net_device_entry__pack
                     (const NetDeviceEntry   *message,
                      uint8_t             *out);
size_t net_device_entry__pack_to_buffer
                     (const NetDeviceEntry   *message,
                      ProtobufCBuffer     *buffer);
NetDeviceEntry *
       net_device_entry__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   net_device_entry__free_unpacked
                     (NetDeviceEntry *message,
                      ProtobufCAllocator *allocator);
/* NetnsId methods */
void   netns_id__init
                     (NetnsId         *message);
size_t netns_id__get_packed_size
                     (const NetnsId   *message);
size_t netns_id__pack
                     (const NetnsId   *message,
                      uint8_t             *out);
size_t netns_id__pack_to_buffer
                     (const NetnsId   *message,
                      ProtobufCBuffer     *buffer);
NetnsId *
       netns_id__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   netns_id__free_unpacked
                     (NetnsId *message,
                      ProtobufCAllocator *allocator);
/* NetnsEntry methods */
void   netns_entry__init
                     (NetnsEntry         *message);
size_t netns_entry__get_packed_size
                     (const NetnsEntry   *message);
size_t netns_entry__pack
                     (const NetnsEntry   *message,
                      uint8_t             *out);
size_t netns_entry__pack_to_buffer
                     (const NetnsEntry   *message,
                      ProtobufCBuffer     *buffer);
NetnsEntry *
       netns_entry__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   netns_entry__free_unpacked
                     (NetnsEntry *message,
                      ProtobufCAllocator *allocator);
/* --- per-message closures --- */

typedef void (*NetDeviceEntry_Closure)
                 (const NetDeviceEntry *message,
                  void *closure_data);
typedef void (*NetnsId_Closure)
                 (const NetnsId *message,
                  void *closure_data);
typedef void (*NetnsEntry_Closure)
                 (const NetnsEntry *message,
                  void *closure_data);

/* --- services --- */


/* --- descriptors --- */

extern const ProtobufCEnumDescriptor    nd_type__descriptor;
extern const ProtobufCMessageDescriptor net_device_entry__descriptor;
extern const ProtobufCMessageDescriptor netns_id__descriptor;
extern const ProtobufCMessageDescriptor netns_entry__descriptor;

PROTOBUF_C__END_DECLS


#endif  /* PROTOBUF_C_netdev_2eproto__INCLUDED */
