RSB  0.7.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
rsb::converter::EventsByScopeMapConverter Class Reference

A converter for aggregated events ordered by their scope and time for each scope. More...

#include <EventsByScopeMapConverter.h>

Inheritance diagram for rsb::converter::EventsByScopeMapConverter:
Inheritance graph
Collaboration diagram for rsb::converter::EventsByScopeMapConverter:
Collaboration graph

Public Member Functions

 EventsByScopeMapConverter (ConverterSelectionStrategy< std::string >::Ptr serializationConverters=converterRepository< std::string >()->getConvertersForSerialization(), ConverterSelectionStrategy< std::string >::Ptr deserializationConverters=converterRepository< std::string >()->getConvertersForDeserialization())
 Constructs a new converter and optionally allows to specify a converter::Repository which will be used for the contained events of arbitrary types.
virtual ~EventsByScopeMapConverter ()
std::string getClassName () const
std::string serialize (const AnnotatedData &data, std::string &wire)
 Serialized the given domain object to the wire.
AnnotatedData deserialize (const std::string &wireSchema, const std::string &wire)
 Deserializes a domain object from a wire type.
std::string getWireSchema () const
 Returns the name of the wire schema this converter can (de)serialize from/to.
- Public Member Functions inherited from rsb::converter::Converter< std::string >
virtual ~Converter ()
virtual std::string getDataType () const
 Returns the name of the data type this converter is applicable for.

Private Attributes

ConverterSelectionStrategy
< std::string >::Ptr 
serializationConverters
ConverterSelectionStrategy
< std::string >::Ptr 
deserializationConverters
Converter< std::string >::Ptr converter

Additional Inherited Members

- Public Types inherited from rsb::converter::Converter< std::string >
typedef boost::shared_ptr
< Converter< std::string > > 
Ptr
- Protected Member Functions inherited from rsb::converter::Converter< std::string >
 Converter (const std::string &dataType, const std::string &wireSchema, bool dummy=true)
 Creates a new instance of this class with automatic handling for types.
 Converter (const std::string &wireSchema, const DataType *=0)
 Creates a new instance of this class with a data type string that is inferred based on the template parameter DataType.

Detailed Description

A converter for aggregated events ordered by their scope and time for each scope.

Author
jwienke

Definition at line 46 of file EventsByScopeMapConverter.h.

Constructor & Destructor Documentation

rsb::converter::EventsByScopeMapConverter::EventsByScopeMapConverter ( ConverterSelectionStrategy< std::string >::Ptr  serializationConverters = converterRepository<std::string>()->getConvertersForSerialization(),
ConverterSelectionStrategy< std::string >::Ptr  deserializationConverters = converterRepository<std::string>()->getConvertersForDeserialization() 
)

Constructs a new converter and optionally allows to specify a converter::Repository which will be used for the contained events of arbitrary types.

Parameters
serializationConvertersconverters to use for serialization. Defaults to the unambiguous map from stringConverterRepository
deserializationConvertersconverters to use for deserialization. Defaults to the unambiguous map from stringConverterRepository

Definition at line 46 of file EventsByScopeMapConverter.cpp.

rsb::converter::EventsByScopeMapConverter::~EventsByScopeMapConverter ( )
virtual

Definition at line 57 of file EventsByScopeMapConverter.cpp.

Member Function Documentation

AnnotatedData rsb::converter::EventsByScopeMapConverter::deserialize ( const std::string &  wireSchema,
const std::string &  wire 
)
virtual

Deserializes a domain object from a wire type.

Parameters
wireSchematype of the wire message
wirethe wire containing the data
Returns
the deserialized domain object annotated with its data type name
Exceptions
SerializationExceptionif deserializing the message fails

Implements rsb::converter::Converter< std::string >.

Definition at line 121 of file EventsByScopeMapConverter.cpp.

References deserializationConverters, rsb::protocol::fillEvent(), rsb::converter::ConverterSelectionStrategy< WireType >::getConverter(), rsb::converter::Converter< std::string >::getDataType(), and getWireSchema().

Here is the call graph for this function:

string rsb::converter::EventsByScopeMapConverter::getClassName ( ) const

Reimplemented from rsb::converter::Converter< std::string >.

Definition at line 64 of file EventsByScopeMapConverter.cpp.

string rsb::converter::EventsByScopeMapConverter::getWireSchema ( ) const
virtual

Returns the name of the wire schema this converter can (de)serialize from/to.

Returns
name of the wire schema from/to this converter can (de)serialize

Reimplemented from rsb::converter::Converter< std::string >.

Definition at line 60 of file EventsByScopeMapConverter.cpp.

References converter, and rsb::converter::Converter< WireType >::getWireSchema().

Referenced by deserialize().

Here is the call graph for this function:

Here is the caller graph for this function:

string rsb::converter::EventsByScopeMapConverter::serialize ( const AnnotatedData data,
std::string &  wire 
)
virtual

Serialized the given domain object to the wire.

Parameters
datadata to serialize
wirethe wire to serialize on
Returns
the wire schema the data is encoded with
Exceptions
SerializationExceptionif the serialization failed

Implements rsb::converter::Converter< std::string >.

Definition at line 68 of file EventsByScopeMapConverter.cpp.

References converter, rsb::protocol::fillNotificationHeader(), rsb::protocol::fillNotificationId(), rsb::converter::ConverterSelectionStrategy< WireType >::getConverter(), rsb::converter::Converter< std::string >::getDataType(), serializationConverters, rsb::converter::Converter< WireType >::serialize(), and rsb::converter::Converter< std::string >::wireSchema.

Here is the call graph for this function:

Member Data Documentation

Converter<std::string>::Ptr rsb::converter::EventsByScopeMapConverter::converter
private

Definition at line 80 of file EventsByScopeMapConverter.h.

Referenced by getWireSchema(), and serialize().

ConverterSelectionStrategy<std::string>::Ptr rsb::converter::EventsByScopeMapConverter::deserializationConverters
private

Definition at line 79 of file EventsByScopeMapConverter.h.

Referenced by deserialize().

ConverterSelectionStrategy<std::string>::Ptr rsb::converter::EventsByScopeMapConverter::serializationConverters
private

Definition at line 78 of file EventsByScopeMapConverter.h.

Referenced by serialize().


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