Tidying
This commit is contained in:
@@ -7,11 +7,11 @@ namespace Bloom::Exceptions
|
||||
class DeviceCommunicationFailure: public Exception
|
||||
{
|
||||
public:
|
||||
explicit DeviceCommunicationFailure(const std::string& message) : Exception(message) {
|
||||
explicit DeviceCommunicationFailure(const std::string& message): Exception(message) {
|
||||
this->message = message;
|
||||
}
|
||||
|
||||
explicit DeviceCommunicationFailure(const char* message) : Exception(message) {
|
||||
explicit DeviceCommunicationFailure(const char* message): Exception(message) {
|
||||
this->message = std::string(message);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include <stdexcept>
|
||||
|
||||
namespace Bloom::Exceptions
|
||||
{
|
||||
class Exception: public std::runtime_error
|
||||
@@ -9,13 +10,13 @@ namespace Bloom::Exceptions
|
||||
std::string message;
|
||||
|
||||
public:
|
||||
explicit Exception() : std::runtime_error("") {}
|
||||
explicit Exception(): std::runtime_error("") {}
|
||||
|
||||
explicit Exception(const std::string& message) : std::runtime_error(message.c_str()) {
|
||||
explicit Exception(const std::string& message): std::runtime_error(message.c_str()) {
|
||||
this->message = message;
|
||||
}
|
||||
|
||||
explicit Exception(const char* message) : std::runtime_error(message) {
|
||||
explicit Exception(const char* message): std::runtime_error(message) {
|
||||
this->message = std::string(message);
|
||||
}
|
||||
|
||||
|
||||
@@ -6,11 +6,11 @@ namespace Bloom::Exceptions
|
||||
class InvalidConfig: public Exception
|
||||
{
|
||||
public:
|
||||
explicit InvalidConfig(const std::string& message) : Exception(message) {
|
||||
explicit InvalidConfig(const std::string& message): Exception(message) {
|
||||
this->message = message;
|
||||
}
|
||||
|
||||
explicit InvalidConfig(const char* message) : Exception(message) {
|
||||
explicit InvalidConfig(const char* message): Exception(message) {
|
||||
this->message = std::string(message);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -6,11 +6,11 @@ namespace Bloom::Exceptions
|
||||
class TargetControllerStartupFailure: public Exception
|
||||
{
|
||||
public:
|
||||
explicit TargetControllerStartupFailure(const std::string& message) : Exception(message) {
|
||||
explicit TargetControllerStartupFailure(const std::string& message): Exception(message) {
|
||||
this->message = message;
|
||||
}
|
||||
|
||||
explicit TargetControllerStartupFailure(const char* message) : Exception(message) {
|
||||
explicit TargetControllerStartupFailure(const char* message): Exception(message) {
|
||||
this->message = std::string(message);
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user