HaikuDepot: notify work status from main window
[haiku.git] / src / tools / gensyscalls / gensyscalls_common.h
blobf61d43214fbe76cfd549cf41a88753e0e6adccb8
1 // gensyscalls_common.h
3 #ifndef _GEN_SYSCALLS_COMMON_H
4 #define _GEN_SYSCALLS_COMMON_H
6 #include <exception>
7 #include <string>
9 using namespace std;
11 // Exception
12 struct Exception : exception {
13 Exception()
14 : fMessage()
18 Exception(const string &message)
19 : fMessage(message)
23 virtual ~Exception() throw() {}
25 virtual const char *what() const throw()
27 return fMessage.c_str();
30 private:
31 string fMessage;
34 // EOFException
35 struct EOFException : public Exception {
36 EOFException() {}
37 EOFException(const string &message) : Exception(message) {}
38 virtual ~EOFException() throw() {}
41 // IOException
42 struct IOException : public Exception {
43 IOException() {}
44 IOException(const string &message) : Exception(message) {}
45 virtual ~IOException() throw() {}
48 // ParseException
49 struct ParseException : public Exception {
50 ParseException() {}
51 ParseException(const string &message) : Exception(message) {}
52 virtual ~ParseException() throw() {}
55 #endif // _GEN_SYSCALLS_COMMON_H