16 #ifndef SURGSIM_DEVICES_DEVICEFILTERS_FILTEREDDEVICE_H 17 #define SURGSIM_DEVICES_DEVICEFILTERS_FILTEREDDEVICE_H 19 #include <boost/thread/shared_mutex.hpp> 30 class InputConsumerInterface;
31 class OutputProducerInterface;
51 std::string getName()
const override;
53 bool initialize()
override;
55 bool isInitialized()
const override;
57 bool addInputConsumer(std::shared_ptr<Input::InputConsumerInterface> inputConsumer)
override;
58 bool removeInputConsumer(std::shared_ptr<Input::InputConsumerInterface> inputConsumer)
override;
59 void clearInputConsumers()
override;
60 bool setOutputProducer(std::shared_ptr<Input::OutputProducerInterface> outputProducer)
override;
61 bool removeOutputProducer(std::shared_ptr<Input::OutputProducerInterface> outputProducer)
override;
62 bool hasOutputProducer()
override;
63 void clearOutputProducer()
override;
67 void setDevice(std::shared_ptr<Input::DeviceInterface> device);
73 void addFilter(std::shared_ptr<DeviceFilter> filter);
76 const std::vector<std::shared_ptr<Input::DeviceInterface>>& getDevices()
const;
81 bool setDevices(
const std::vector<std::shared_ptr<Input::DeviceInterface>>& devices);
84 bool finalize()
override;
98 std::vector<std::shared_ptr<Input::DeviceInterface>>
m_devices;
110 #endif // SURGSIM_DEVICES_DEVICEFILTERS_FILTEREDDEVICE_H Definition: CompoundShapeToGraphics.cpp:29
std::string m_name
The name of this device.
Definition: FilteredDevice.h:90
std::vector< std::shared_ptr< Input::DeviceInterface > > m_devices
The devices.
Definition: FilteredDevice.h:98
std::shared_ptr< Framework::Logger > m_logger
The logger.
Definition: FilteredDevice.h:104
boost::shared_mutex m_deviceMutex
The mutex to protect access to the devices.
Definition: FilteredDevice.h:101
bool m_initialized
true if initialized and not finalized.
Definition: FilteredDevice.h:93
A DeviceInterface connected in series with one or more DeviceFilters. Useful for serialization.
Definition: FilteredDevice.h:39
#define SURGSIM_CLASSNAME(ClassName)
Declare the class name of a class with the appropriate function header, do not use quotes...
Definition: Macros.h:21