libdballe 9.6
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
dballe::Exporter Class Referenceabstract

Message exporter interface. More...

#include <exporter.h>

Inheritance diagram for dballe::Exporter:
dballe::BulletinExporter dballe::impl::msg::JsonExporter dballe::impl::msg::WRExporter dballe::impl::msg::BufrExporter dballe::impl::msg::CrexExporter

Public Member Functions

 Exporter (const Exporter &)=delete
 
 Exporter (Exporter &&)=delete
 
Exporteroperator= (const Exporter &)=delete
 
Exporteroperator= (Exporter &&)=delete
 
virtual std::string to_binary (const std::vector< std::shared_ptr< Message > > &messages) const =0
 Encode a message.
 
virtual std::unique_ptr< wreport::Bulletinto_bulletin (const std::vector< std::shared_ptr< Message > > &msgs) const
 Export to a Bulletin.
 
virtual std::unique_ptr< wreport::Bulletinmake_bulletin () const
 Create a bulletin that works with this exporter.
 

Static Public Member Functions

static std::unique_ptr< Exportercreate (Encoding type, const ExporterOptions &opts=ExporterOptions::defaults)
 Instantiate the right importer for the given type.
 

Protected Member Functions

 Exporter (const ExporterOptions &opts)
 

Protected Attributes

ExporterOptions opts
 

Detailed Description

Message exporter interface.

Member Function Documentation

◆ make_bulletin()

virtual std::unique_ptr< wreport::Bulletin > dballe::Exporter::make_bulletin ( ) const
virtual

Create a bulletin that works with this exporter.

Returns
the bulletin, or NULL of this is an exporter for a format not covered by Bulletin

Reimplemented in dballe::impl::msg::BufrExporter, and dballe::impl::msg::CrexExporter.

◆ to_binary()

virtual std::string dballe::Exporter::to_binary ( const std::vector< std::shared_ptr< Message > > &  messages) const
pure virtual

Encode a message.

Parameters
messagesMessage to encode
Returns
The resulting encoded data

◆ to_bulletin()

virtual std::unique_ptr< wreport::Bulletin > dballe::Exporter::to_bulletin ( const std::vector< std::shared_ptr< Message > > &  msgs) const
virtual

Export to a Bulletin.

Reimplemented in dballe::BulletinExporter.


The documentation for this class was generated from the following file: