Container class for StreamTypeSerializer.
More...
#include <adtf_file_writer.h>
Container class for StreamTypeSerializer.
◆ add()
void adtf_file::StreamTypeSerializers::add |
( |
const std::shared_ptr< StreamTypeSerializer > & |
serializer | ) |
|
|
inline |
Adds a StreamTypeSerializer instance to the container.
- Parameters
-
serializer | the serializer instance to add |
◆ getAdtf2TypeId()
std::string adtf_file::StreamTypeSerializers::getAdtf2TypeId |
( |
const StreamType & |
stream_type | ) |
|
|
inline |
Get the ADTF 2 type id of the stream_type
.
- Parameters
-
stream_type | the stream type to retireve the ADTF 2 type id for |
- Returns
- std::string the ADTF 2 type id
- Return values
-
empty | std::string() if no StreamTypeSerializer supports ADTF 2 types for the meta type of stream_type |
◆ serialize()
void adtf_file::StreamTypeSerializers::serialize |
( |
const StreamType & |
stream_type, |
|
|
OutputStream & |
stream |
|
) |
| const |
|
inline |
Serialzes the given stream type into the given stream. It will use the StreamTypeSerializer supporting the meta type of the given stream type.
- Parameters
-
stream_type | the stream type to serialize |
stream | the stream to write to |
- Exceptions
-
std::runtime_error | if no added serializer supports the meta type of the given stream_type |
The documentation for this class was generated from the following file: