B15F
Board 15 Famulus Edition
control
src
drv
driverexception.h
1
#ifndef DRIVEREXCEPTION_H
2
#define DRIVEREXCEPTION_H
3
4
#include <exception>
5
6
// SOURCE: https://stackoverflow.com/a/8152888
7
8
class
DriverException
:
public
std::exception
9
{
10
public
:
11
explicit
DriverException
(
const
char
* message) : msg_(message)
12
{
13
}
14
15
explicit
DriverException
(
const
std::string& message) : msg_(message)
16
{
17
}
18
19
virtual
~
DriverException
()
throw
()
20
{
21
}
22
23
virtual
const
char
* what()
const
throw
()
24
{
25
return
msg_.c_str();
26
}
27
28
protected
:
29
std::string msg_;
30
};
31
32
#endif // DRIVEREXCEPTION_H
33
DriverException
Definition:
driverexception.h:8
Generated by
1.8.16