Nix (Dev) 3.5.10
dev - 3.5.10 - 1af9301
Loading...
Searching...
No Matches
exceptions.hpp
Go to the documentation of this file.
1#ifndef IV_SRC_COMMS_SERIAL_EXCEPTIONS_HPP_
2#define IV_SRC_COMMS_SERIAL_EXCEPTIONS_HPP_
3
4#include "core/exception.hpp"
5
6namespace iv::exception
7{
8
10{
11public:
12 explicit SerialPortException(std::string_view description)
13 : iv::exception::Exception(fmt::format("SerialPort exception {} failed", description))
14 {
15 }
16
17 [[nodiscard]] eExceptionType exceptionType() const noexcept override
18 {
20 }
21};
22
24{
25public:
26 explicit PortNotOpenedException(std::string_view description)
27 : iv::exception::Exception(fmt::format("Port not opened exception {} failed", description))
28 {
29 }
30
31 [[nodiscard]] eExceptionType exceptionType() const noexcept override
32 {
34 }
35};
36
37}// namespace iv::exception
38
39#endif//IV_SRC_COMMS_SERIAL_EXCEPTIONS_HPP_
Definition exception.hpp:88
Definition exceptions.hpp:24
eExceptionType exceptionType() const noexcept override
Definition exceptions.hpp:31
PortNotOpenedException(std::string_view description)
Definition exceptions.hpp:26
Definition exceptions.hpp:10
SerialPortException(std::string_view description)
Definition exceptions.hpp:12
eExceptionType exceptionType() const noexcept override
Definition exceptions.hpp:17
Definition exceptions.hpp:7
eExceptionType
Definition exception.hpp:13
Definition AlarmsManager.cpp:18