29 #ifndef INCLUDE_OLA_RDM_SUBDEVICEDISPATCHER_H_
30 #define INCLUDE_OLA_RDM_SUBDEVICEDISPATCHER_H_
52 struct FanOutTracker {
54 FanOutTracker(uint16_t number_of_subdevices,
57 bool IncrementAndCheckIfComplete() {
58 return ++m_responses_so_far == m_number_of_subdevices;
61 void SetResponse(ola::rdm::rdm_response_code code,
66 uint16_t NumResponses()
const {
67 return m_responses_so_far;
71 uint16_t m_number_of_subdevices;
72 uint16_t m_responses_so_far;
75 ola::rdm::rdm_response_code m_response_code;
79 typedef std::map<uint16_t, ola::rdm::RDMControllerInterface*> SubDeviceMap;
81 SubDeviceMap m_subdevices;
88 ola::rdm::rdm_nack_reason nack_reason);
90 void HandleSubDeviceResponse(
91 FanOutTracker *tracker,
92 ola::rdm::rdm_response_code code,
94 const std::vector<std::string> &packets);
98 #endif // INCLUDE_OLA_RDM_SUBDEVICEDISPATCHER_H_