IBR-DTN
1.0.0
Main Page
Namespaces
Classes
Files
File List
File Members
MutableSerializer.h
Go to the documentation of this file.
1
/*
2
* MutableSerializer.h
3
*
4
* Copyright (C) 2011 IBR, TU Braunschweig
5
*
6
* Written-by: Johannes Morgenroth <morgenroth@ibr.cs.tu-bs.de>
7
*
8
* Licensed under the Apache License, Version 2.0 (the "License");
9
* you may not use this file except in compliance with the License.
10
* You may obtain a copy of the License at
11
*
12
* http://www.apache.org/licenses/LICENSE-2.0
13
*
14
* Unless required by applicable law or agreed to in writing, software
15
* distributed under the License is distributed on an "AS IS" BASIS,
16
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17
* See the License for the specific language governing permissions and
18
* limitations under the License.
19
*
20
*/
21
22
#ifndef __MUTABLE_SERIALIZER_H__
23
#define __MUTABLE_SERIALIZER_H__
24
25
#include "
ibrdtn/data/Serializer.h
"
26
#include "
ibrdtn/security/SecurityBlock.h
"
27
#include "
ibrdtn/data/Number.h
"
28
#include <sys/types.h>
29
30
namespace
dtn
31
{
32
namespace
security
33
{
34
class
SecurityBlock;
35
44
class
MutableSerializer
:
public
dtn::data::DefaultSerializer
45
{
46
public
:
50
static
const
dtn::data::Length
sdnv_size
= 8;
51
57
MutableSerializer
(std::ostream& stream,
const
dtn::data::Block
*ignore = NULL);
58
60
virtual
~MutableSerializer
();
61
69
virtual
Serializer &
operator<<
(
const
dtn::data::PrimaryBlock
&obj);
70
78
virtual
Serializer &
operator<<
(
const
dtn::data::Block
&obj);
79
83
virtual
dtn::data::Length
getLength
(
const
dtn::data::Bundle
&obj);
84
90
virtual
dtn::data::Length
getLength
(
const
dtn::data::PrimaryBlock
&obj)
const
;
91
97
virtual
dtn::data::Length
getLength
(
const
dtn::data::Block
&obj)
const
;
98
105
virtual
Serializer &
operator<<
(
const
uint32_t value);
106
113
virtual
Serializer &
operator<<
(
const
dtn::data::EID
& value);
114
121
virtual
Serializer &
operator<<
(
const
dtn::data::Number
& value);
122
128
virtual
Serializer &
operator<<
(
const
dtn::security::SecurityBlock::TLVList
& list);
129
130
private
:
131
const
dtn::data::Block
*_ignore;
132
bool
_ignore_previous_bundles;
133
};
134
}
135
}
136
137
#endif
dtn::data::PrimaryBlock
Definition:
PrimaryBlock.h:47
dtn::security::MutableSerializer::MutableSerializer
MutableSerializer(std::ostream &stream, const dtn::data::Block *ignore=NULL)
Definition:
MutableSerializer.cpp:41
Serializer.h
dtn::data::SDNV< Size >
dtn::security::MutableSerializer::~MutableSerializer
virtual ~MutableSerializer()
Definition:
MutableSerializer.cpp:46
dtn::data::Length
size_t Length
Definition:
Number.h:33
dtn::security::MutableSerializer
Definition:
MutableSerializer.h:44
dtn::data::EID
Definition:
EID.h:34
dtn::security::MutableSerializer::getLength
virtual dtn::data::Length getLength(const dtn::data::Bundle &obj)
Definition:
MutableSerializer.cpp:137
dtn::data::DefaultSerializer
Definition:
Serializer.h:95
dtn::data::Bundle
Definition:
Bundle.h:52
Number.h
SecurityBlock.h
dtn::data::Block
Definition:
Block.h:39
dtn::security::MutableSerializer::operator<<
virtual Serializer & operator<<(const dtn::data::PrimaryBlock &obj)
Definition:
MutableSerializer.cpp:50
dtn::security::SecurityBlock::TLVList
Definition:
SecurityBlock.h:183
dtn::security::MutableSerializer::sdnv_size
static const dtn::data::Length sdnv_size
Definition:
MutableSerializer.h:50
ibrdtn
ibrdtn
security
MutableSerializer.h
Generated on Sun Jan 4 2015 15:27:34 for IBR-DTN by
1.8.6