myexception.h
来自「socket 编程实例 singleServerMultipleClientSr」· C头文件 代码 · 共 33 行
H
33 行
#ifndef myException_H
#define myException_H
#include <string>
#include <iostream>
using namespace std;
class myException
{
public:
// int: error code, string is the concrete error message
myException(int,const string&);
~myException() {};
/*
how to handle the exception is done here, so
far, just write the message to screen and log file
*/
virtual void response();
int getErrCode() { return errorCode; }
string& getErrMsg() { return errorMsg; }
private:
void initVars();
private:
int errorCode;
string errorMsg;
};
#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?