OpenDaVINCI  4.16.0
PCAPProtocol.h
Go to the documentation of this file.
1 
20 #ifndef OPENDAVINCI_CORE_IO_PROTOCOL_PCAPPROTOCOL_H_
21 #define OPENDAVINCI_CORE_IO_PROTOCOL_PCAPPROTOCOL_H_
22 
23 // core/platform.h must be included to setup platform-dependent header files and configurations.
25 
26 #include <sstream>
27 
33 
34 namespace odcore {
35  namespace io {
36  namespace protocol {
37 
38  using namespace std;
39 
45  private:
51  PCAPProtocol(const PCAPProtocol &);
52 
58  PCAPProtocol& operator=(const PCAPProtocol &);
59 
60  public:
64  PCAPProtocol();
65 
66  virtual ~PCAPProtocol();
67 
68  virtual void setContainerListener(odcore::io::conference::ContainerListener *cl);
69 
70  virtual void nextString(const string &s);
71 
72  private:
73  bool tryConsumingData();
74 
79  void invokeContainerListener(odcore::data::Container &c);
80 
81  odcore::base::Mutex m_containerListenerMutex;
82  odcore::io::conference::ContainerListener *m_containerListener;
83 
84  odcore::base::Mutex m_partialDataMutex;
85  stringstream m_partialData;
86  };
87 
88  }
89  }
90 }
91 
92 #endif /* OPENDAVINCI_CORE_IO_PROTOCOL_PCAPPROTOCOL_H_ */
93 
94 
Definition: ContainerListener.h:35
Definition: ContainerObserver.h:35
Definition: base/Mutex.h:49
Definition: Container.h:40
#define OPENDAVINCI_API
Definition: opendavinci.h:67
Definition: PCAPProtocol.h:43
Definition: AbstractProtocol.h:40