📄 comm_exception.cpp
字号:
#include "stdafx.h"
#include "comm_exception.h"
#include <sstream>
using namespace std;
namespace C2217
{
namespace StdLib
{
ostream & operator << (ostream &out, const comm_exception & e)
{
out<< "what: " <<e.what()<<endl
<< "code: " <<e.get_error_code() <<endl
<< "throw exception at:-----------------" << endl
<< "file: " << e.get_throw_file() <<endl
<< "function:" << e.get_throw_function() <<endl
<< "line: " <<e.get_throw_line()<<endl
<< "catch excetion at:------------------" << endl
<< "file: " << e.get_catch_file()<<endl
<< "function:" << e.get_catch_function()<<endl
<< "line: " <<e.get_catch_line()<<endl;
return out;
}
string comm_exception::str() const
{
stringstream ss;
ss << *this;
return ss.str();
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -