1 |
/** @file |
/** @file |
2 |
* $Source: /home/cvsmanager/yoda/event/log/LogRecord.h,v $ |
* $Source: /home/cvsmanager/yoda/event/log/LogRecord.h,v $ |
3 |
* $Id: LogRecord.h,v 1.3 2004/08/19 15:24:16 kusanagi Exp $ |
* $Id: LogRecord.h,v 4.4 2005/05/28 10:44:09 kusanagi Exp $ |
4 |
* $Author: kusanagi $ |
* $Author: kusanagi $ |
5 |
* |
* |
6 |
* Header file for the LogRecord class. |
* Header file for the LogRecord class. |
7 |
*/ |
*/ |
8 |
#ifndef LOG_RECORD_H |
#ifndef LOG_RECORD_H |
9 |
#define LOG_RECORD_H |
#define LOG_RECORD_H |
10 |
|
#include "../SubPacket.h" |
|
#define UINT32 unsigned int |
|
|
#define UINT16 unsigned short |
|
|
#define UINT8 unsigned char |
|
|
|
|
|
#include <TObject.h> |
|
|
|
|
|
|
|
11 |
namespace pamela { |
namespace pamela { |
12 |
/** |
/** |
13 |
* LogBlock data Wrapper |
* LogRecord data Wrapper |
14 |
|
* |
15 |
|
* Each pamela::LogRecord represents a PAMELA CPU software?s error or other software conditions. |
16 |
|
* The pair (FILE_ID,LINE) identifies a unique error/log trace that can be found in all source code: |
17 |
|
* this gives the maximum of the information with the minimum of size |
18 |
|
* (this information also goes in part to the history area). |
19 |
*/ |
*/ |
20 |
class LogRecord: public TObject { |
class LogRecord: public TObject { |
21 |
private: |
private: |
22 |
|
|
23 |
public: |
public: |
24 |
/** |
/** |
25 |
* Get the run name according to a certain run number. |
* The On-Board-Time of the Record. |
|
* @param run Run number. |
|
|
* @return a string with the run name. |
|
26 |
*/ |
*/ |
27 |
UINT32 RECORD_OBT; |
UINT32 RECORD_OBT; |
28 |
|
|
29 |
|
/** |
30 |
|
* The Type of the Record. |
31 |
|
* |
32 |
|
* BITMASK description: <BR> |
33 |
|
* #define LU_WARNING (1<<0) <BR> |
34 |
|
* #define LU_CRITICAL (1<<1) <BR> |
35 |
|
* #define LU_INTERNAL (1<<2) <BR> |
36 |
|
* #define LU_FATAL (1<<3) <BR> |
37 |
|
* #define LU_NORMAL_TRACE (1<<4) <BR> |
38 |
|
* #define LU_DEBUG_TRACE (1<<5) <BR> |
39 |
|
* #define LU_ALARM (1<<6) <BR> |
40 |
|
* #define LU_HA (1<<7) <BR> |
41 |
|
* <B> The first seven bits are mutually esclusive. </B> |
42 |
|
* Bit 8 indicates if this log is also recorded in the history area. |
43 |
|
*/ |
44 |
UINT8 MASKTYPE; |
UINT8 MASKTYPE; |
45 |
|
|
46 |
|
/** |
47 |
|
* The FileId of the record. |
48 |
|
* Identification code of a specific PAMELA CPU software ".c" file in which this error/log trace occurred. |
49 |
|
* Each source file is identified by a unique number in the range [0,255]. |
50 |
|
*/ |
51 |
UINT8 FILE_ID; |
UINT8 FILE_ID; |
52 |
|
|
53 |
|
/** |
54 |
|
* The Line_No of te record. |
55 |
|
* Identify the line number inside the file code referred by the FILE_ID parameter. |
56 |
|
*/ |
57 |
UINT16 LINE_NO; |
UINT16 LINE_NO; |
58 |
|
|
59 |
|
/** |
60 |
|
* Supplementary field which depends on the related log trace. |
61 |
|
*/ |
62 |
UINT32 INFO1; |
UINT32 INFO1; |
63 |
|
|
64 |
LogRecord(void); |
LogRecord(void); |