IBR-DTNSuite  0.8
dtn::data::ScopeControlHopLimitBlock Class Reference

#include <ScopeControlHopLimitBlock.h>

Inheritance diagram for dtn::data::ScopeControlHopLimitBlock:
Collaboration diagram for dtn::data::ScopeControlHopLimitBlock:

List of all members.

Classes

class  Factory

Public Member Functions

 ScopeControlHopLimitBlock ()
virtual ~ScopeControlHopLimitBlock ()
size_t getHopsToLive () const
void increment (size_t hops=1)
void setLimit (size_t hops)
virtual size_t getLength () const
virtual std::ostream & serialize (std::ostream &stream, size_t &length) const
virtual std::istream & deserialize (std::istream &stream, const size_t length)

Static Public Attributes

static const char BLOCK_TYPE = 199

Detailed Description

Definition at line 19 of file ScopeControlHopLimitBlock.h.


Constructor & Destructor Documentation


Member Function Documentation

std::istream & dtn::data::ScopeControlHopLimitBlock::deserialize ( std::istream &  stream,
const size_t  length 
) [virtual]

Deserialize the derived block payload.

Parameters:
streamA input stream to deserialize from.
Returns:
The same reference as given with the stream parameter.

Implements dtn::data::Block.

Definition at line 60 of file ScopeControlHopLimitBlock.cpp.

Definition at line 30 of file ScopeControlHopLimitBlock.cpp.

References dtn::data::SDNV::getValue().

Referenced by dtn::data::MetaBundle::MetaBundle(), and dtn::storage::SQLiteDatabase::store().

Here is the call graph for this function:

Return the length of the payload, if this were an abstract block. It is the length put in the third field, after block type and processing flags.

Implements dtn::data::Block.

Definition at line 47 of file ScopeControlHopLimitBlock.cpp.

References dtn::data::SDNV::getLength().

Referenced by serialize().

Here is the call graph for this function:

std::ostream & dtn::data::ScopeControlHopLimitBlock::serialize ( std::ostream &  stream,
size_t &  length 
) const [virtual]

Serialize the derived block payload.

Parameters:
streamA output stream to serialize into.
Returns:
The same reference as given with the stream parameter.

Implements dtn::data::Block.

Definition at line 52 of file ScopeControlHopLimitBlock.cpp.

References getLength().

Here is the call graph for this function:


Member Data Documentation

Definition at line 30 of file ScopeControlHopLimitBlock.h.


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