client-cpp  0.8.1
ILogCollector.hpp
Go to the documentation of this file.
1 
17 #ifndef ILOGCOLLECTOR_HPP_
18 #define ILOGCOLLECTOR_HPP_
19 
20 #include <future>
21 
22 #include "kaa/log/gen/LogDefinitions.hpp"
23 #include "kaa/log/ILogStorage.hpp"
26 #include "kaa/log/RecordFuture.hpp"
27 
33 namespace kaa {
34 
35 /*
36  * Forward declaration.
37  */
38 struct LogSyncResponse;
39 
55 public:
67  virtual RecordFuture addLogRecord(const KaaUserLogRecord& record) = 0;
68 
78  virtual void setStorage(ILogStoragePtr storage) = 0;
79 
89  virtual void setUploadStrategy(ILogUploadStrategyPtr strategy) = 0;
90 
96  virtual void setLogDeliveryListener(ILogDeliveryListenerPtr listener) = 0;
97 
98  virtual ~ILogCollector() {}
99 };
100 
101 } // namespace kaa
102 
103 #endif /* ILOGCOLLECTOR_HPP_ */
104 
std::shared_ptr< ILogDeliveryListener > ILogDeliveryListenerPtr
virtual void setStorage(ILogStoragePtr storage)=0
Sets the new log storage.
std::shared_ptr< ILogStorage > ILogStoragePtr
Definition: ILogStorage.hpp:93
virtual RecordFuture addLogRecord(const KaaUserLogRecord &record)=0
Adds a new log record to the log storage.
virtual void setUploadStrategy(ILogUploadStrategyPtr strategy)=0
Sets the new log upload strategy.
The public interface to the Kaa log collecting subsystem.
virtual void setLogDeliveryListener(ILogDeliveryListenerPtr listener)=0
Set a listener which receives a delivery status of each log bucket.
std::shared_ptr< ILogUploadStrategy > ILogUploadStrategyPtr
virtual ~ILogCollector()