📄 exception.hpp
字号:
/* ======================================================================== *\ | | | JOYIT Communication Technology | Copyright (C) 2002-2003, All Right Reserved. | | System: Programmable Signaling Gateway | Sub-system: MTP3 | Filename: werror.hpp | Environment: LINUX -- Red Hat 7.2 & GNU C/C++ Compiler 2.96 | vxWorks -- Tornado 2.0 & vxWorks 5.4 | Function description: Declare error message data structure and the | information about the error code. |\* ======================================================================== */#ifndef _EXCEPTION_HPP#define _EXCEPTION_HPP#ifndef _WERROR_HPP#include "werror.hpp"#endif#ifndef _LOGFILE_HPP#include "logfile.hpp"#endifclass Exception{public: Exception(int ms, const char * const logfilename); ~Exception( );public: void idle( );public: void SetLogFileName(const char * const logfilename); void error(ERRCOD_T werr, UINT16 mid, const char * em = NULL); void error(const char * em); void error(const char * cn, const char * fn, ERRCOD_T werr, const char * em = NULL); // Add 2005-01-14, by Wujianjin.public: const char * GetFirst( ); const char * GetNext( ); const char * GetLast( ); const char * LastError(ERRCOD_T& werr, UINT16& mid); // Return the last error message information.private: ERRCOD_T errorCode; // Last error code. UINT16 objId; // The module that last error occur. char hasMessage; // The flag to identify whether there is message associate with the error.private: char *memblock; int memsize; // In byte. char errmsg[MAX_ERROR_MESSAGE_HOLDER][MAX_ERROR_MESSAGE_LENGTH]; // Message length could't exceed 128 byte, include the NULL byte. INT8 nonceindex; // The pointer point to the current error message container. INT8 queryindex;private: char logit; // Message log to file flag. 0: don't record; 1: record. LogFile log;};extern Exception *xcpPtr;#endif// ------------------------------------------------------------------------//// Revision list.// ==============//// 1.0, 2003-04-18, Wu jianjin// Initial version.// 1.1, 2003-05-19, Wu jianjin// Ported to vxWorks.//// ------------------------------------------------------------------------
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -