39 lines
886 B
C++
39 lines
886 B
C++
/*
|
|
* InputFactory.h
|
|
*
|
|
* Created on: Apr 5, 2018
|
|
* Author: Andreas Schneider, Johannes Wendel, Jonas Zeunert, Rafael Vinci, Dr. Franca Rupprecht
|
|
*/
|
|
|
|
#ifndef INPUTFACTORY_H_
|
|
#define INPUTFACTORY_H_
|
|
|
|
#include <istream>
|
|
#include <atomic>
|
|
|
|
#include "Detector.h"
|
|
#include "IInputDriver.h"
|
|
|
|
#include "utilities/InputGPIOInterface.h"
|
|
#include "json/json.hpp"
|
|
#include "IEventNotifier.h"
|
|
|
|
namespace FlippR_Driver
|
|
{
|
|
namespace Input
|
|
{
|
|
class InputDriverFactory
|
|
{
|
|
|
|
public:
|
|
static std::shared_ptr<IInputDriver> get_InputDriver(std::istream& input_config_stream, std::istream& matrix_config_stream);
|
|
|
|
private:
|
|
static void create_input_events(nlohmann::json matrix_config,
|
|
std::map<char, std::shared_ptr<DistributingEvent>>& address_event_map,
|
|
std::map<std::string, std::shared_ptr<Event>>& name_event_map,
|
|
std::shared_ptr<IEventNotifier> event_notifier);
|
|
};
|
|
}
|
|
}
|
|
#endif |