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

#ifndef PROTOBUF_C_peer_2fadmin_2eproto__INCLUDED
#define PROTOBUF_C_peer_2fadmin_2eproto__INCLUDED

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

PROTOBUF_C__BEGIN_DECLS

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

#include "google/protobuf/empty.pb-c.h"
#include "common/common.pb-c.h"

typedef struct _Protos__ServerStatus Protos__ServerStatus;
typedef struct _Protos__LogLevelRequest Protos__LogLevelRequest;
typedef struct _Protos__LogLevelResponse Protos__LogLevelResponse;
typedef struct _Protos__LogSpecRequest Protos__LogSpecRequest;
typedef struct _Protos__LogSpecResponse Protos__LogSpecResponse;
typedef struct _Protos__AdminOperation Protos__AdminOperation;


/* --- enums --- */

typedef enum _Protos__ServerStatus__StatusCode {
  PROTOS__SERVER_STATUS__STATUS_CODE__UNDEFINED = 0,
  PROTOS__SERVER_STATUS__STATUS_CODE__STARTED = 1,
  PROTOS__SERVER_STATUS__STATUS_CODE__STOPPED = 2,
  PROTOS__SERVER_STATUS__STATUS_CODE__PAUSED = 3,
  PROTOS__SERVER_STATUS__STATUS_CODE__ERROR = 4,
  PROTOS__SERVER_STATUS__STATUS_CODE__UNKNOWN = 5
    PROTOBUF_C__FORCE_ENUM_TO_BE_INT_SIZE(PROTOS__SERVER_STATUS__STATUS_CODE)
} Protos__ServerStatus__StatusCode;

/* --- messages --- */

struct  _Protos__ServerStatus
{
  ProtobufCMessage base;
  protobuf_c_boolean has_status;
  Protos__ServerStatus__StatusCode status;
};
#define PROTOS__SERVER_STATUS__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&protos__server_status__descriptor) \
    , 0,0 }


struct  _Protos__LogLevelRequest
{
  ProtobufCMessage base;
  char *log_module;
  char *log_level;
};
#define PROTOS__LOG_LEVEL_REQUEST__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&protos__log_level_request__descriptor) \
    , NULL, NULL }


struct  _Protos__LogLevelResponse
{
  ProtobufCMessage base;
  char *log_module;
  char *log_level;
};
#define PROTOS__LOG_LEVEL_RESPONSE__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&protos__log_level_response__descriptor) \
    , NULL, NULL }


struct  _Protos__LogSpecRequest
{
  ProtobufCMessage base;
  char *log_spec;
};
#define PROTOS__LOG_SPEC_REQUEST__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&protos__log_spec_request__descriptor) \
    , NULL }


struct  _Protos__LogSpecResponse
{
  ProtobufCMessage base;
  char *log_spec;
  char *error;
};
#define PROTOS__LOG_SPEC_RESPONSE__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&protos__log_spec_response__descriptor) \
    , NULL, NULL }


typedef enum {
  PROTOS__ADMIN_OPERATION__CONTENT__NOT_SET = 0,
  PROTOS__ADMIN_OPERATION__CONTENT_LOG_REQ = 1,
  PROTOS__ADMIN_OPERATION__CONTENT_LOG_SPEC_REQ = 2,
} Protos__AdminOperation__ContentCase;

struct  _Protos__AdminOperation
{
  ProtobufCMessage base;
  Protos__AdminOperation__ContentCase content_case;
  union {
    Protos__LogLevelRequest *logreq;
    Protos__LogSpecRequest *logspecreq;
  };
};
#define PROTOS__ADMIN_OPERATION__INIT \
 { PROTOBUF_C_MESSAGE_INIT (&protos__admin_operation__descriptor) \
    , PROTOS__ADMIN_OPERATION__CONTENT__NOT_SET, {0} }


/* Protos__ServerStatus methods */
void   protos__server_status__init
                     (Protos__ServerStatus         *message);
size_t protos__server_status__get_packed_size
                     (const Protos__ServerStatus   *message);
size_t protos__server_status__pack
                     (const Protos__ServerStatus   *message,
                      uint8_t             *out);
size_t protos__server_status__pack_to_buffer
                     (const Protos__ServerStatus   *message,
                      ProtobufCBuffer     *buffer);
Protos__ServerStatus *
       protos__server_status__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   protos__server_status__free_unpacked
                     (Protos__ServerStatus *message,
                      ProtobufCAllocator *allocator);
/* Protos__LogLevelRequest methods */
void   protos__log_level_request__init
                     (Protos__LogLevelRequest         *message);
size_t protos__log_level_request__get_packed_size
                     (const Protos__LogLevelRequest   *message);
size_t protos__log_level_request__pack
                     (const Protos__LogLevelRequest   *message,
                      uint8_t             *out);
size_t protos__log_level_request__pack_to_buffer
                     (const Protos__LogLevelRequest   *message,
                      ProtobufCBuffer     *buffer);
Protos__LogLevelRequest *
       protos__log_level_request__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   protos__log_level_request__free_unpacked
                     (Protos__LogLevelRequest *message,
                      ProtobufCAllocator *allocator);
/* Protos__LogLevelResponse methods */
void   protos__log_level_response__init
                     (Protos__LogLevelResponse         *message);
size_t protos__log_level_response__get_packed_size
                     (const Protos__LogLevelResponse   *message);
size_t protos__log_level_response__pack
                     (const Protos__LogLevelResponse   *message,
                      uint8_t             *out);
size_t protos__log_level_response__pack_to_buffer
                     (const Protos__LogLevelResponse   *message,
                      ProtobufCBuffer     *buffer);
Protos__LogLevelResponse *
       protos__log_level_response__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   protos__log_level_response__free_unpacked
                     (Protos__LogLevelResponse *message,
                      ProtobufCAllocator *allocator);
/* Protos__LogSpecRequest methods */
void   protos__log_spec_request__init
                     (Protos__LogSpecRequest         *message);
size_t protos__log_spec_request__get_packed_size
                     (const Protos__LogSpecRequest   *message);
size_t protos__log_spec_request__pack
                     (const Protos__LogSpecRequest   *message,
                      uint8_t             *out);
size_t protos__log_spec_request__pack_to_buffer
                     (const Protos__LogSpecRequest   *message,
                      ProtobufCBuffer     *buffer);
Protos__LogSpecRequest *
       protos__log_spec_request__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   protos__log_spec_request__free_unpacked
                     (Protos__LogSpecRequest *message,
                      ProtobufCAllocator *allocator);
/* Protos__LogSpecResponse methods */
void   protos__log_spec_response__init
                     (Protos__LogSpecResponse         *message);
size_t protos__log_spec_response__get_packed_size
                     (const Protos__LogSpecResponse   *message);
size_t protos__log_spec_response__pack
                     (const Protos__LogSpecResponse   *message,
                      uint8_t             *out);
size_t protos__log_spec_response__pack_to_buffer
                     (const Protos__LogSpecResponse   *message,
                      ProtobufCBuffer     *buffer);
Protos__LogSpecResponse *
       protos__log_spec_response__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   protos__log_spec_response__free_unpacked
                     (Protos__LogSpecResponse *message,
                      ProtobufCAllocator *allocator);
/* Protos__AdminOperation methods */
void   protos__admin_operation__init
                     (Protos__AdminOperation         *message);
size_t protos__admin_operation__get_packed_size
                     (const Protos__AdminOperation   *message);
size_t protos__admin_operation__pack
                     (const Protos__AdminOperation   *message,
                      uint8_t             *out);
size_t protos__admin_operation__pack_to_buffer
                     (const Protos__AdminOperation   *message,
                      ProtobufCBuffer     *buffer);
Protos__AdminOperation *
       protos__admin_operation__unpack
                     (ProtobufCAllocator  *allocator,
                      size_t               len,
                      const uint8_t       *data);
void   protos__admin_operation__free_unpacked
                     (Protos__AdminOperation *message,
                      ProtobufCAllocator *allocator);
/* --- per-message closures --- */

typedef void (*Protos__ServerStatus_Closure)
                 (const Protos__ServerStatus *message,
                  void *closure_data);
typedef void (*Protos__LogLevelRequest_Closure)
                 (const Protos__LogLevelRequest *message,
                  void *closure_data);
typedef void (*Protos__LogLevelResponse_Closure)
                 (const Protos__LogLevelResponse *message,
                  void *closure_data);
typedef void (*Protos__LogSpecRequest_Closure)
                 (const Protos__LogSpecRequest *message,
                  void *closure_data);
typedef void (*Protos__LogSpecResponse_Closure)
                 (const Protos__LogSpecResponse *message,
                  void *closure_data);
typedef void (*Protos__AdminOperation_Closure)
                 (const Protos__AdminOperation *message,
                  void *closure_data);

/* --- services --- */

typedef struct _Protos__Admin_Service Protos__Admin_Service;
struct _Protos__Admin_Service
{
  ProtobufCService base;
  void (*get_status)(Protos__Admin_Service *service,
                     const Common__Envelope *input,
                     Protos__ServerStatus_Closure closure,
                     void *closure_data);
  void (*start_server)(Protos__Admin_Service *service,
                       const Common__Envelope *input,
                       Protos__ServerStatus_Closure closure,
                       void *closure_data);
  void (*get_module_log_level)(Protos__Admin_Service *service,
                               const Common__Envelope *input,
                               Protos__LogLevelResponse_Closure closure,
                               void *closure_data);
  void (*set_module_log_level)(Protos__Admin_Service *service,
                               const Common__Envelope *input,
                               Protos__LogLevelResponse_Closure closure,
                               void *closure_data);
  void (*revert_log_levels)(Protos__Admin_Service *service,
                            const Common__Envelope *input,
                            Google__Protobuf__Empty_Closure closure,
                            void *closure_data);
  void (*get_log_spec)(Protos__Admin_Service *service,
                       const Common__Envelope *input,
                       Protos__LogSpecResponse_Closure closure,
                       void *closure_data);
  void (*set_log_spec)(Protos__Admin_Service *service,
                       const Common__Envelope *input,
                       Protos__LogSpecResponse_Closure closure,
                       void *closure_data);
};
typedef void (*Protos__Admin_ServiceDestroy)(Protos__Admin_Service *);
void protos__admin__init (Protos__Admin_Service *service,
                          Protos__Admin_ServiceDestroy destroy);
#define PROTOS__ADMIN__BASE_INIT \
    { &protos__admin__descriptor, protobuf_c_service_invoke_internal, NULL }
#define PROTOS__ADMIN__INIT(function_prefix__) \
    { PROTOS__ADMIN__BASE_INIT,\
      function_prefix__ ## get_status,\
      function_prefix__ ## start_server,\
      function_prefix__ ## get_module_log_level,\
      function_prefix__ ## set_module_log_level,\
      function_prefix__ ## revert_log_levels,\
      function_prefix__ ## get_log_spec,\
      function_prefix__ ## set_log_spec  }
void protos__admin__get_status(ProtobufCService *service,
                               const Common__Envelope *input,
                               Protos__ServerStatus_Closure closure,
                               void *closure_data);
void protos__admin__start_server(ProtobufCService *service,
                                 const Common__Envelope *input,
                                 Protos__ServerStatus_Closure closure,
                                 void *closure_data);
void protos__admin__get_module_log_level(ProtobufCService *service,
                                         const Common__Envelope *input,
                                         Protos__LogLevelResponse_Closure closure,
                                         void *closure_data);
void protos__admin__set_module_log_level(ProtobufCService *service,
                                         const Common__Envelope *input,
                                         Protos__LogLevelResponse_Closure closure,
                                         void *closure_data);
void protos__admin__revert_log_levels(ProtobufCService *service,
                                      const Common__Envelope *input,
                                      Google__Protobuf__Empty_Closure closure,
                                      void *closure_data);
void protos__admin__get_log_spec(ProtobufCService *service,
                                 const Common__Envelope *input,
                                 Protos__LogSpecResponse_Closure closure,
                                 void *closure_data);
void protos__admin__set_log_spec(ProtobufCService *service,
                                 const Common__Envelope *input,
                                 Protos__LogSpecResponse_Closure closure,
                                 void *closure_data);

/* --- descriptors --- */

extern const ProtobufCMessageDescriptor protos__server_status__descriptor;
extern const ProtobufCEnumDescriptor    protos__server_status__status_code__descriptor;
extern const ProtobufCMessageDescriptor protos__log_level_request__descriptor;
extern const ProtobufCMessageDescriptor protos__log_level_response__descriptor;
extern const ProtobufCMessageDescriptor protos__log_spec_request__descriptor;
extern const ProtobufCMessageDescriptor protos__log_spec_response__descriptor;
extern const ProtobufCMessageDescriptor protos__admin_operation__descriptor;
extern const ProtobufCServiceDescriptor protos__admin__descriptor;

PROTOBUF_C__END_DECLS


#endif  /* PROTOBUF_C_peer_2fadmin_2eproto__INCLUDED */
