|
BCNP 3.2.1
Batched Command Network Protocol
|
Drives a PacketDispatcher from a transport adapter. More...
#include <controller_driver.h>
Public Member Functions | |
| DispatcherDriver (PacketDispatcher &dispatcher, DuplexAdapter &adapter) | |
| void | PollOnce () |
| Poll transport and feed data to dispatcher. | |
| bool | SendBytes (const uint8_t *data, std::size_t length) |
| Send raw bytes through the adapter. | |
| template<typename MsgType > | |
| bool | SendPacket (const TypedPacket< MsgType > &packet) |
| Send a typed packet. | |
Drives a PacketDispatcher from a transport adapter.
Connects a network transport (TCP, UDP, etc.) to a PacketDispatcher, polling for incoming data and feeding it to the parser.
Definition at line 25 of file controller_driver.h.
| bcnp::DispatcherDriver::DispatcherDriver | ( | PacketDispatcher & | dispatcher, |
| DuplexAdapter & | adapter ) |
Definition at line 7 of file controller_driver.cpp.
| void bcnp::DispatcherDriver::PollOnce | ( | ) |
Poll transport and feed data to dispatcher.
Definition at line 13 of file controller_driver.cpp.
| bool bcnp::DispatcherDriver::SendBytes | ( | const uint8_t * | data, |
| std::size_t | length ) |
Send raw bytes through the adapter.
Definition at line 25 of file controller_driver.cpp.
|
inline |
Send a typed packet.
Definition at line 37 of file controller_driver.h.