00001 #ifndef TRANSPORT_PEER_HPP_ 00002 #define TRANSPORT_PEER_HPP_ 00003 00004 #include "ariba/config.h" 00005 #include "transport_protocol.hpp" 00006 #include "ariba/utility/addressing/endpoint_set.hpp" 00007 00008 // namespace ariba::transport 00009 namespace ariba { 00010 namespace transport { 00011 00012 using namespace ariba::addressing; 00013 00014 class tcpip; 00015 #ifdef HAVE_LIBBLUETOOTH 00016 class rfcomm; 00017 #endif 00018 00024 00025 00026 class transport_peer : public transport_protocol { 00027 public: 00028 transport_peer( endpoint_set& local_set ); 00029 virtual ~transport_peer(); 00030 virtual void start(); 00031 virtual void stop(); 00032 virtual void send( const address_v* remote, const uint8_t* data, size_t size ); 00033 virtual void send( const endpoint_set& endpoints, const uint8_t* data, size_t size ); 00034 virtual void terminate( const address_v* remote ); 00035 virtual void register_listener( transport_listener* listener ); 00036 00037 private: 00038 endpoint_set& local; 00039 tcpip* tcp; 00040 #ifdef HAVE_LIBBLUETOOTH 00041 rfcomm* rfc; 00042 #endif 00043 }; 00044 00045 }} // namespace ariba::transport 00046 00047 #endif /* TRANSPORT_PEER_HPP_ */