aboutsummaryrefslogtreecommitdiff
path: root/src/p18/exceptions.h
diff options
context:
space:
mode:
authorEvgeny Zinoviev <me@ch1p.io>2021-05-07 02:18:07 +0300
committerEvgeny Zinoviev <me@ch1p.io>2021-05-07 02:18:07 +0300
commit7e743b73433475df086fcec81be7b10c1d695a42 (patch)
tree1737c5f9bdad2a40f740e9a655e510641331b9e2 /src/p18/exceptions.h
initial
Diffstat (limited to 'src/p18/exceptions.h')
-rw-r--r--src/p18/exceptions.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/p18/exceptions.h b/src/p18/exceptions.h
new file mode 100644
index 0000000..9b79082
--- /dev/null
+++ b/src/p18/exceptions.h
@@ -0,0 +1,22 @@
+// SPDX-License-Identifier: BSD-3-Clause
+
+#ifndef INFINISOLAR_TOOLS_P18_EXCEPTIONS_H
+#define INFINISOLAR_TOOLS_P18_EXCEPTIONS_H
+
+#include <stdexcept>
+
+namespace p18 {
+
+class InvalidResponseError : public std::runtime_error {
+public:
+ using std::runtime_error::runtime_error;
+};
+
+class ParseError : public InvalidResponseError {
+public:
+ using InvalidResponseError::InvalidResponseError;
+};
+
+}
+
+#endif //INFINISOLAR_TOOLS_P18_EXCEPTIONS_H