SUMO - Simulation of Urban MObility
Main Page
Related Pages
Modules
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
UtilExceptions.h
Go to the documentation of this file.
1
/****************************************************************************/
10
// Exceptions for used by some utility classes
11
/****************************************************************************/
12
// SUMO, Simulation of Urban MObility; see http://sumo.sourceforge.net/
13
// Copyright (C) 2001-2013 DLR (http://www.dlr.de/) and contributors
14
/****************************************************************************/
15
//
16
// This file is part of SUMO.
17
// SUMO is free software: you can redistribute it and/or modify
18
// it under the terms of the GNU General Public License as published by
19
// the Free Software Foundation, either version 3 of the License, or
20
// (at your option) any later version.
21
//
22
/****************************************************************************/
23
#ifndef UtilExceptions_h
24
#define UtilExceptions_h
25
26
27
// ===========================================================================
28
// included modules
29
// ===========================================================================
30
#ifdef _MSC_VER
31
#include <
windows_config.h
>
32
#else
33
#include <
config.h
>
34
#endif
35
36
#include <string>
37
#include <stdexcept>
38
39
40
// ===========================================================================
41
// class definitions
42
// ===========================================================================
48
class
InvalidArgument
:
public
std::runtime_error {
49
public
:
51
InvalidArgument
(
const
std::string& message)
52
: std::runtime_error(message) {}
53
54
};
55
56
63
class
ProcessError
:
public
std::runtime_error {
64
public
:
66
ProcessError
()
67
: std::runtime_error(
"Process Error"
) {}
68
70
ProcessError
(
const
std::string& msg)
71
: std::runtime_error(msg) {}
72
73
};
74
75
80
class
EmptyData
:
public
std::runtime_error {
81
public
:
83
EmptyData
()
84
: std::runtime_error(
"Empty Data"
) {}
85
86
};
87
88
94
class
FormatException
:
public
std::runtime_error {
95
public
:
97
FormatException
(
const
std::string& msg)
98
: std::runtime_error(msg) {}
99
100
};
101
102
109
class
NumberFormatException
:
public
FormatException
{
110
public
:
112
NumberFormatException
()
113
:
FormatException
(
"Number Format"
) {}
114
115
};
116
117
123
class
BoolFormatException
:
public
FormatException
{
124
public
:
126
BoolFormatException
()
127
:
FormatException
(
"Bool Format"
) {}
128
129
};
130
131
137
class
OutOfBoundsException
:
public
std::runtime_error {
138
public
:
140
OutOfBoundsException
()
141
: std::runtime_error(
"Out Of Bounds"
) {}
142
143
};
144
145
151
class
UnknownElement
:
public
std::runtime_error {
152
public
:
154
UnknownElement
()
155
: std::runtime_error(
"Unknown Element"
) {}
156
158
UnknownElement
(
const
std::string& msg)
159
: std::runtime_error(msg) {}
160
161
};
162
163
164
class
IOError
:
public
ProcessError
{
165
public
:
167
IOError
(
const
std::string& message)
168
:
ProcessError
(message) {}
169
170
};
171
172
173
#endif
174
175
/****************************************************************************/
build
buildd
sumo-0.17.1~dfsg
src
utils
common
UtilExceptions.h
Generated on Sun Jun 16 2013 17:30:20 for SUMO - Simulation of Urban MObility by
1.8.3.1