File indexing completed on 2025-08-03 08:20:46
0001
0002 #ifndef __MSG_BUFFER_H__
0003 #define __MSG_BUFFER_H__
0004
0005
0006 #include "event_io.h"
0007
0008 #ifdef __CINT__
0009 #include <iostream>
0010 #endif
0011
0012
0013 #ifndef __CINT__
0014
0015 #include <cstdio>
0016 #include <cstdarg>
0017 #include <string>
0018 #include <ctime>
0019 #include <time.h>
0020
0021 #endif
0022
0023
0024 #include "msg_control.h"
0025
0026
0027
0028 #define MSG_EXTENSION_AMOUNT 32
0029
0030
0031 typedef struct msgProfile {
0032 int type;
0033 int source;
0034 int severity;
0035 int reserved1;
0036 int reserved2;
0037 int reserved3;
0038 char sourcecomponent[256];
0039 } msgProfile;
0040
0041
0042
0043
0044
0045
0046
0047
0048
0049
0050
0051
0052
0053
0054
0055
0056
0057
0058
0059
0060
0061
0062
0063
0064 #ifdef __CINT__
0065 class msg_buffer : public streambuf {
0066 #else
0067 class msg_buffer : public STREAMBUF {
0068 #endif
0069
0070 protected:
0071 char *oBuffer;
0072 int pos;
0073 int maximum_position;
0074 msg_control *m;
0075
0076 virtual char * format(int * length, msgProfile *mp);
0077
0078
0079
0080 public:
0081 msg_buffer (const int msglen=256);
0082 virtual ~msg_buffer();
0083
0084 virtual int overflow (int ch);
0085 virtual int sync ();
0086 };
0087
0088 #ifndef __CINT__
0089 void streambuf_add_date (STREAMBUF * sb);
0090 #endif
0091
0092
0093 #endif