proto_defs.h 2.89 KB
Newer Older
Tomek Mrugalski's avatar
Tomek Mrugalski committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
// This file is generated from ./proto_defs.cc
// by the const2hdr.py script.
// Do not edit, all changes will be lost.

// Copyright (C) 2013  Internet Systems Consortium, Inc. ("ISC")
//
// Permission to use, copy, modify, and/or distribute this software for any
// purpose with or without fee is hereby granted, provided that the above
// copyright notice and this permission notice appear in all copies.
//
// THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
// REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
// AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
// INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
// LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
// OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
// PERFORMANCE OF THIS SOFTWARE.

19 20
#ifndef KEA_COMMON_DEFS_H
#define KEA_COMMON_DEFS_H
Tomek Mrugalski's avatar
Tomek Mrugalski committed
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73

// \file proto_defs.h
// \brief Common shared constants

// This file contains common definitions of constasts used across the sources.
// It includes, but is not limited to the definitions of messages sent from
// one process to another. Since the names should be self-explanatory and
// the variables here are used mostly to synchronize the same values across
// multiple programs, separate documentation for each variable is not provided.

namespace isc {
namespace cc {

// Aside from defining the values for the C++ library, this file is also
// used as direct input of the generator of the python counterpart. Please,
// keep the syntax here simple and check the generated file
// (lib/python/isc/cc/proto_defs.py) is correct and sane.

// The constants used in the CC protocol
// First the header names
extern const char* const CC_HEADER_TYPE;
extern const char* const CC_HEADER_FROM;
extern const char* const CC_HEADER_TO;
extern const char* const CC_HEADER_GROUP;
extern const char* const CC_HEADER_INSTANCE;
extern const char* const CC_HEADER_SEQ;
extern const char* const CC_HEADER_WANT_ANSWER;
extern const char* const CC_HEADER_REPLY;
// The commands in the "type" header
extern const char* const CC_COMMAND_SEND;
extern const char* const CC_COMMAND_SUBSCRIBE;
extern const char* const CC_COMMAND_UNSUBSCRIBE;
extern const char* const CC_COMMAND_GET_LNAME;
extern const char* const CC_COMMAND_PING;
extern const char* const CC_COMMAND_PONG;
extern const char* const CC_COMMAND_STOP;
// The wildcards of some headers
extern const char* const CC_TO_WILDCARD;
extern const char* const CC_INSTANCE_WILDCARD;
// Prefixes for groups
extern const char* const CC_GROUP_NOTIFICATION_PREFIX;
// Reply codes
extern const int CC_REPLY_NO_RECPT;
extern const int CC_REPLY_SUCCESS;
// Payload in the message
extern const char *const CC_PAYLOAD_LNAME;
extern const char *const CC_PAYLOAD_RESULT;
extern const char *const CC_PAYLOAD_COMMAND;
extern const char *const CC_PAYLOAD_NOTIFICATION;

}
}
#endif