RTI Recording Service Version 7.1.0
StorageReader.hpp
Go to the documentation of this file.
1/*
2 * (c) Copyright, Real-Time Innovations, 2018-.
3 * All rights reserved.
4 * No duplications, whole or partial, manual or electronic, may be made
5 * without express written permission. Any such copies, or
6 * revisions thereof, must display this notice unaltered.
7 * This code contains trade secrets of Real-Time Innovations, Inc.
8 */
9
10#ifndef HPP_RECORDER_DB_REPLAYPLUGIN_HPP_
11#define HPP_RECORDER_DB_REPLAYPLUGIN_HPP_
12
13#include "dds/dds.hpp"
14#include "rti/recording/PropertySet.hpp"
15#include "rti/recording/StreamInfo.hpp"
16
17#include "StorageStreamInfoReader.hpp"
18#include "rti/recording/storage/StorageStreamReader.hpp"
19
31namespace rti {
32
38namespace recording {
39
45namespace storage {
46
58public:
59
60 typedef void* SampleType;
61 typedef void* InfoType;
62 typedef std::vector<SampleType> SampleSeqType;
63 typedef std::vector<InfoType> InfoSeqType;
64
93 StorageReader(const rti::recording::PropertySet& properties)
94 {
95 RTI_UNUSED_PARAMETER(properties);
96 }
97
102 {
103 }
104
130 const rti::recording::PropertySet& properties) = 0;
131
138 StorageStreamInfoReader *stream_info_reader) = 0;
139
168 const rti::recording::StreamInfo& stream_info,
169 const rti::recording::PropertySet& properties) = 0;
170
176 virtual void delete_stream_reader(StorageStreamReader *stream_reader) = 0;
177
178private:
179
180 StorageReader() {}
181
182};
183
184} } } /* namespace rti::recording::storage */
185
186#include "rti/recording/storage/detail/StorageReaderForwarder.hpp"
187#include "rti/routing/ServiceProperty.hpp"
188#include "rti/routing/detail/ForwarderUtils.hpp"
189
211#define RTI_RECORDING_STORAGE_READER_CREATE_DECL(STORAGE_READER_CLASS) \
212extern "C" RTI_USER_DLL_EXPORT \
213struct RTI_RecordingServiceStorageReader * \
214STORAGE_READER_CLASS ## _get_storage_reader( \
215 const struct RTI_RoutingServiceProperties *);
216
225#define RTI_RECORDING_STORAGE_READER_CREATE_DEF(STORAGE_READER_CLASS) \
226struct RTI_RecordingServiceStorageReader * \
227STORAGE_READER_CLASS ## _get_storage_reader( \
228 const struct RTI_RoutingServiceProperties *native_properties) \
229{ \
230 rti::recording::PropertySet properties; \
231 rti::routing::PropertyAdapter::add_properties_from_native( \
232 properties, \
233 native_properties); \
234 return new rti::recording::storage::detail::StorageReaderForwarder( \
235 new STORAGE_READER_CLASS(properties)); \
236}
237
238#endif /* HPP_RECORDER_DB_REPLAYPLUGIN_HPP_ */
239
Storage reader.
Definition: StorageReader.hpp:57
virtual StorageStreamInfoReader * create_stream_info_reader(const rti::recording::PropertySet &properties)=0
Replay Service calls this to create a stream in charge of discovering information about the available...
virtual void delete_stream_info_reader(StorageStreamInfoReader *stream_info_reader)=0
Replay Service calls this to delete a stream information reader.
virtual ~StorageReader()
Virtual destructor.
Definition: StorageReader.hpp:101
StorageReader(const rti::recording::PropertySet &properties)
Constructor.
Definition: StorageReader.hpp:93
virtual StorageStreamReader * create_stream_reader(const rti::recording::StreamInfo &stream_info, const rti::recording::PropertySet &properties)=0
Replay Service calls this to create a user-data stream reader.
virtual void delete_stream_reader(StorageStreamReader *stream_reader)=0
Replay Service calls this to delete a stream reader.
Storage discovery stream reader.
Definition: StorageStreamInfoReader.hpp:31
Storage stream reader.
Definition: StorageStreamReader.hpp:31
The RTI namespace.
Definition: RecordingServiceImpl.hpp:22