summaryrefslogtreecommitdiff
path: root/src/libnml/nml/stat_msg.hh
blob: 192d12f1907a4d5216c2e78a1ba8012f2b1ec28c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
/********************************************************************
* Description: stat_msg.hh
*
*   Derived from a work by Fred Proctor & Will Shackleford
*
* Author:
* License: LGPL Version 2
* System: Linux
*    
* Copyright (c) 2004 All rights reserved.
*
* Last change: 
********************************************************************/
#ifndef RCS_STAT_HH
#define RCS_STAT_HH

#include "nml.hh"
#include "nmlmsg.hh"

class RCS_STAT_MSG:public NMLmsg {
  public:
    RCS_STAT_MSG(NMLTYPE t, size_t sz);
    NMLTYPE command_type;
    int echo_serial_number;
    int status;
    int state;
    int line;
    int source_line;
    char source_file[64];

};

extern int RCS_STAT_MSG_format(NMLTYPE, void *, CMS *);

class RCS_STAT_CHANNEL:public NML {
  public:
    RCS_STAT_CHANNEL(NML_FORMAT_PTR, const char *, const char *, const char *,
	int set_to_server = 0);
     ~RCS_STAT_CHANNEL();
    RCS_STAT_MSG *get_address() {
	return ((RCS_STAT_MSG *) NML::get_address());
    };
};

#define RCS_GENERIC_STATUS_TYPE         ((NMLTYPE) 2000000)

class RCS_GENERIC_STATUS:public RCS_STAT_MSG {
  public:
    RCS_GENERIC_STATUS();
    void update(CMS *);
};

enum RCS_STATE
{
  UNINITIALIZED_STATE = -1,
  NEW_COMMAND = -2,
  NOP_STATE = -3,
  SE0 = -10,
  SE1 = -11,
  SE2 = -12,
  SE3 = -13,
  SE4 = -14,
  SE5 = -15,
  SE6 = -16,
  SE7 = -17,
  SE8 = -18,
  SE9 = -19,
  S0 = 0,
  S1 = 1,
  S2 = 2,
  S3 = 3,
  S4 = 4,
  S5 = 5,
  S6 = 6,
  S7 = 7,
  S8 = 8,
  S9 = 9,
  S10 = 10,
  S11 = 11,
  S12 = 12,
  S13 = 13,
  S14 = 14,
  S15 = 15,
  S16 = 16,
  S17 = 17,
  S18 = 18,
  S19 = 19,
  S20 = 20,
  S21 = 21,
  S22 = 22,
  S23 = 23,
  S24 = 24,
  S25 = 25,
  S26 = 26,
  S27 = 27,
  S28 = 28,
  S29 = 29,
  S30 = 30,
  S31 = 31,
  S32 = 32,
  S33 = 33,
  S34 = 34,
  S35 = 35,
  S36 = 36,
  S37 = 37,
  S38 = 38,
  S39 = 39
};

#endif