some code convention stuff
This commit is contained in:
@@ -22,9 +22,7 @@ namespace FlippR_Driver
|
|||||||
{
|
{
|
||||||
namespace Input
|
namespace Input
|
||||||
{
|
{
|
||||||
|
std::shared_ptr<IInputDriver> InputDriverFactory::get_InputDriver(std::istream &input_config_stream, std::istream &matrix_config_stream)
|
||||||
std::shared_ptr<IInputDriver>
|
|
||||||
InputDriverFactory::get_InputDriver(std::istream &input_config_stream, std::istream &matrix_config_stream)
|
|
||||||
{
|
{
|
||||||
LoggerFactory::CreateInputLogger();
|
LoggerFactory::CreateInputLogger();
|
||||||
|
|
||||||
@@ -46,8 +44,7 @@ namespace Input
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void InputDriverFactory::create_input_events(json matrix_config, std::map<char, std::shared_ptr<Event>>& address_event_map,
|
||||||
InputDriverFactory::create_input_events(json matrix_config, std::map<char, std::shared_ptr<Event>>& address_event_map,
|
|
||||||
std::map<std::string, std::shared_ptr<Event>>& name_event_map)
|
std::map<std::string, std::shared_ptr<Event>>& name_event_map)
|
||||||
{
|
{
|
||||||
auto& event_array = matrix_config.at("input_matrix");
|
auto& event_array = matrix_config.at("input_matrix");
|
||||||
@@ -65,11 +62,13 @@ namespace Input
|
|||||||
address_event_map.emplace(address, event_ptr);
|
address_event_map.emplace(address, event_ptr);
|
||||||
name_event_map.emplace(name, event_ptr);
|
name_event_map.emplace(name, event_ptr);
|
||||||
}
|
}
|
||||||
catch (json::exception &e) {
|
catch (json::exception &e)
|
||||||
|
{
|
||||||
CLOG(ERROR, INPUT_LOGGER) << "Matrix config-file corrupted: " << e.what();
|
CLOG(ERROR, INPUT_LOGGER) << "Matrix config-file corrupted: " << e.what();
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user