source: dev/trunk/jenga/include/smoothie/SmoothieException.h@ 172

Last change on this file since 172 was 172, checked in by dai_9181, 17 years ago
File size: 692 bytes
Line 
1#pragma once
2
3#include <string>
4#include <vector>
5
6class SmoothieException
7{
8 int errorCode;
9 std::string keyword;
10 int nowLine;
11public:
12 SmoothieException( int errorCode, const std::string &keyword, int nowLine )
13 : errorCode( errorCode )
14 , keyword( keyword )
15 , nowLine( nowLine )
16 {
17 }
18 SmoothieException( int errorCode )
19 : errorCode( errorCode )
20 , keyword( "" )
21 , nowLine( -1 )
22 {
23 }
24 SmoothieException()
25 : errorCode( 300 )
26 , keyword( "" )
27 , nowLine( -1 )
28 {
29 }
30
31 int GetErrorCode() const
32 {
33 return errorCode;
34 }
35 const std::string &GetKeyword() const
36 {
37 return keyword;
38 }
39 int GetNowLine() const
40 {
41 return nowLine;
42 }
43};
Note: See TracBrowser for help on using the repository browser.