BeeeOn Gateway  v2020.3.1-2-g6f737dc
Platform to interconnect the IoT world
InMemoryQueuingStrategy.h
1 #pragma once
2 
3 #include <vector>
4 
5 #include <Poco/SharedPtr.h>
6 
7 #include "exporters/QueuingStrategy.h"
8 
9 namespace BeeeOn {
10 
18 public:
19  typedef Poco::SharedPtr<InMemoryQueuingStrategy> Ptr;
20 
24  bool empty() override;
25 
29  size_t size();
30 
35  void push(const std::vector<SensorData> &data) override;
36 
46  size_t peek(std::vector<SensorData> &data, size_t count) override;
47 
52  void pop(size_t count) override;
53 
54 private:
55  std::vector<SensorData> m_vector;
56 };
57 
58 }
size_t peek(std::vector< SensorData > &data, size_t count) override
Definition: InMemoryQueuingStrategy.cpp:26
size_t size()
Definition: InMemoryQueuingStrategy.cpp:16
bool empty() override
Definition: InMemoryQueuingStrategy.cpp:11
Basic implementation of the QueuingStrategy interface.
Definition: InMemoryQueuingStrategy.h:17
Definition: QueuingStrategy.h:18
void pop(size_t count) override
Definition: InMemoryQueuingStrategy.cpp:36
void push(const std::vector< SensorData > &data) override
Definition: InMemoryQueuingStrategy.cpp:21