IBR-DTNSuite  0.8
ibrdtn/ibrdtn/security/StrictSerializer.h
Go to the documentation of this file.
00001 #ifndef __STRICT_SERIALIZER_H__
00002 #define __STRICT_SERIALIZER_H__
00003 
00004 #include "ibrdtn/data/Serializer.h"
00005 #include "ibrdtn/security/SecurityBlock.h"
00006 
00007 namespace dtn
00008 {
00009         namespace security
00010         {
00019                 class StrictSerializer : public dtn::data::DefaultSerializer
00020                 {
00021                         public:
00025                                 StrictSerializer(std::ostream& stream, const SecurityBlock::BLOCK_TYPES type = SecurityBlock::BUNDLE_AUTHENTICATION_BLOCK, const bool with_correlator = false, const u_int64_t correlator = 0);
00026 
00028                                 virtual ~StrictSerializer();
00029 
00040                                 virtual dtn::data::Serializer &operator<<(const dtn::data::Bundle &obj);
00041 
00042                                 virtual dtn::data::Serializer &operator<<(const dtn::data::Block &obj);
00043 
00044                         private:
00045                                 const dtn::security::SecurityBlock::BLOCK_TYPES _block_type;
00046                                 const bool _with_correlator;
00047                                 const u_int64_t _correlator;
00048                 };
00049         }
00050 }
00051 
00052 #endif