RTI Recording Service Version 7.1.0
StorageWriter.hpp
Go to the documentation of this file.
1/*
2 * (c) Copyright, Real-Time Innovations, 2016-.
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#include "rti/recording/PropertySet.hpp"
11#include "rti/recording/StreamInfo.hpp"
12#include "rti/recording/storage/StorageStreamWriter.hpp"
13#include "rti/recording/storage/StorageDiscoveryStreamWriter.hpp"
14#include "dds/dds.hpp"
15
16#ifndef HPP_RTI_RECORDING_STORAGE_STORAGEWRITER_HPP_
17#define HPP_RTI_RECORDING_STORAGE_STORAGEWRITER_HPP_
18
26namespace rti { namespace recording { namespace storage {
27
37public:
38
66 StorageWriter(const rti::recording::PropertySet& properties)
67 {
68 RTI_UNUSED_PARAMETER(properties);
69 }
70
74 virtual ~StorageWriter() {}
75
92 const rti::recording::StreamInfo& stream_info,
93 const rti::recording::PropertySet& properties) = 0;
94
104 {
105 return NULL;
106 }
107
117 {
118 return NULL;
119 }
120
130 {
131 return NULL;
132 }
133
140 virtual void delete_stream_writer(StorageStreamWriter *writer) = 0;
141
142private:
143
144 StorageWriter() {}
145};
146
147} } } /* namespace rti::recording::storage */
148
149#include "rti/recording/storage/detail/StorageWriterForwarder.hpp"
150#include "rti/routing/ServiceProperty.hpp"
151#include "rti/routing/detail/ForwarderUtils.hpp"
152
174#define RTI_RECORDING_STORAGE_WRITER_CREATE_DECL(STORAGE_WRITER_CLASS) \
175extern "C" RTI_USER_DLL_EXPORT \
176struct RTI_RecordingServiceStorageWriter * \
177STORAGE_WRITER_CLASS ## _get_storage_writer( \
178 const struct RTI_RoutingServiceProperties *);
179
188#define RTI_RECORDING_STORAGE_WRITER_CREATE_DEF(STORAGE_WRITER_CLASS) \
189struct RTI_RecordingServiceStorageWriter * \
190STORAGE_WRITER_CLASS ## _get_storage_writer( \
191 const struct RTI_RoutingServiceProperties *native_properties) \
192{ \
193 rti::recording::PropertySet properties; \
194 rti::routing::PropertyAdapter::add_properties_from_native( \
195 properties, \
196 native_properties); \
197 return new rti::recording::storage::detail::StorageWriterForwarder( \
198 new STORAGE_WRITER_CLASS(properties)); \
199}
200
201#endif /* HPP_RTI_RECORDING_STORAGE_STORAGEWRITER_HPP_ */
Storage stream writer.
Definition: StorageStreamWriter.hpp:28
Storage writer.
Definition: StorageWriter.hpp:36
virtual ParticipantStorageWriter * create_participant_writer()
RTI Recording Service calls this to create a stream writer for the DDS built-in topic DCPSParticipant...
Definition: StorageWriter.hpp:103
virtual PublicationStorageWriter * create_publication_writer()
RTI Recording Service calls this to create a stream writer for the DDS built-in topic DCPSPublication...
Definition: StorageWriter.hpp:116
virtual SubscriptionStorageWriter * create_subscription_writer()
RTI Recording Service calls this to create a stream writer for the DDS built-in topic DCPSSubscriptio...
Definition: StorageWriter.hpp:129
virtual ~StorageWriter()
Virtual destructor.
Definition: StorageWriter.hpp:74
virtual StorageStreamWriter * create_stream_writer(const rti::recording::StreamInfo &stream_info, const rti::recording::PropertySet &properties)=0
RTI Recording Service calls this to create a user-data stream writer. The built-in DDS discovery topi...
virtual void delete_stream_writer(StorageStreamWriter *writer)=0
RTI Recording Service calls this to delete a stream writer. This method should be able to work with a...
StorageWriter(const rti::recording::PropertySet &properties)
Constructor.
Definition: StorageWriter.hpp:66
A templatized wrapping implementation of StorageStreamWriter, providing a strongly-typed interface re...
Definition: StorageStreamWriter.hpp:65
The RTI namespace.
Definition: RecordingServiceImpl.hpp:22