Line | |
---|
1 | #ifndef TRANSPORT_PEER_HPP_
|
---|
2 | #define TRANSPORT_PEER_HPP_
|
---|
3 |
|
---|
4 | #include "ariba/config.h"
|
---|
5 | #include "transport_protocol.hpp"
|
---|
6 | #include "ariba/utility/addressing/endpoint_set.hpp"
|
---|
7 |
|
---|
8 | // namespace ariba::transport
|
---|
9 | namespace ariba {
|
---|
10 | namespace transport {
|
---|
11 |
|
---|
12 | using namespace ariba::addressing;
|
---|
13 |
|
---|
14 | class tcpip;
|
---|
15 | #ifdef HAVE_LIBBLUETOOTH
|
---|
16 | class rfcomm;
|
---|
17 | #endif
|
---|
18 |
|
---|
19 | /**
|
---|
20 | * TODO: Doc
|
---|
21 | *
|
---|
22 | * @author Sebastian Mies <mies@tm.uka.de>
|
---|
23 | */
|
---|
24 | /// this transport peer allocates implementations of various transport
|
---|
25 | /// protocols and can send messages to an entire set of endpoints
|
---|
26 | class transport_peer : public transport_protocol {
|
---|
27 | public:
|
---|
28 | transport_peer( endpoint_set& local_set );
|
---|
29 | virtual ~transport_peer();
|
---|
30 | virtual void start();
|
---|
31 | virtual void stop();
|
---|
32 | virtual void send( const address_v* remote, const uint8_t* data, size_t size );
|
---|
33 | virtual void send( const endpoint_set& endpoints, const uint8_t* data, size_t size );
|
---|
34 | virtual void terminate( const address_v* remote );
|
---|
35 | virtual void register_listener( transport_listener* listener );
|
---|
36 |
|
---|
37 | private:
|
---|
38 | endpoint_set& local;
|
---|
39 | tcpip* tcp;
|
---|
40 | #ifdef HAVE_LIBBLUETOOTH
|
---|
41 | rfcomm* rfc;
|
---|
42 | #endif
|
---|
43 | };
|
---|
44 |
|
---|
45 | }} // namespace ariba::transport
|
---|
46 |
|
---|
47 | #endif /* TRANSPORT_PEER_HPP_ */
|
---|
Note:
See
TracBrowser
for help on using the repository browser.