Elm  1.0
ELM is a library providing generic data structures, OS-independent interface, plugins and XML.
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
SystemException.h
1 /*
2  * SystemException class interface
3  *
4  * This file is part of OTAWA
5  * Copyright (c) 2005-12, IRIT UPS.
6  *
7  * OTAWA is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation; either version 2 of the License, or
10  * (at your option) any later version.
11  *
12  * OTAWA is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with OTAWA; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
20  */
21 #ifndef ELM_SYS_SYSTEM_EXCEPTION_H
22 #define ELM_SYS_SYSTEM_EXCEPTION_H
23 
24 #include <elm/utility.h>
25 
26 namespace elm { namespace sys {
27 
28 // SystemException class
29 class SystemException: public Exception {
30 public:
31  typedef enum error_t {
32  OK = 0,
38  } error_t;
39 
40 private:
41  error_t err;
42  String msg;
43 
44 public:
45  SystemException(error_t err, String msg);
46  SystemException(int code, String header);
47  inline error_t error(void) const;
48 
49  // Exception overload
50  virtual String message(void);
51 };
52 
53 // Inlines
55  return err;
56 }
57 
58 } } // elm::sys
59 
60 #endif // ELM_SYS_SYSTEM_EXCEPTION_H
61 
error_t error(void) const
Definition: SystemException.h:54
SystemException(error_t err, String msg)
Definition: system_SystemException.cpp:43
Definition: SystemException.h:34
Definition: SystemException.h:35
Definition: SystemException.h:32
Definition: SystemException.h:29
Definition: Exception.h:30
error_t
Definition: SystemException.h:31
Definition: SystemException.h:37
virtual String message(void)
Definition: system_SystemException.cpp:107
Definition: String.h:31
Definition: SystemException.h:33
Definition: SystemException.h:36