MockBundle Class Reference
[pydtn]

Derived type of DTN::Bundle designed for simulating large data sizes. More...

#include <pydtn/MockBundle.h>

Inheritance diagram for MockBundle:

Inheritance graph
[legend]
Collaboration diagram for MockBundle:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 MockBundle (uint32_t seq, const DTN::ByteString &src, const DTN::ByteString &dest, unsigned int dataSize, const struct timeval &creat, const struct timeval &expir, BundleType t=kData, const DTN::ByteString &app=DTN::ByteString())
 Fully specified constructor.
 MockBundle (const MockBundle &aOther)
 Copy constructor.
virtual ~MockBundle ()
 Destructor.
virtual DTN::Bundleclone () const
 
Returns:
a copy of the bundle

unsigned int size () const
 
Returns:
the total size (in bytes) of the bundle


Detailed Description

Derived type of DTN::Bundle designed for simulating large data sizes.

Since we don't want to actually allocate all of the storage, this instead stores the desired payload size, with the underlying DTN::Bundle holding a 0-size payload bytestring.

Definition at line 46 of file MockBundle.h.


Constructor & Destructor Documentation

MockBundle::MockBundle ( uint32_t  seq,
const DTN::ByteString &  src,
const DTN::ByteString &  dest,
unsigned int  dataSize,
const struct timeval &  creat,
const struct timeval &  expir,
BundleType  t = kData,
const DTN::ByteString &  app = DTN::ByteString() 
)

Fully specified constructor.

Parameters:
seq The sequence number of the bundle at src
src ByteString representation of the bundle's source
dest ByteString representation of the bundle's destination
dataSize The size of the bundle's payload
creat Creation time
expir Creation time
t The type of bundle
app The application type of the bundle

Definition at line 33 of file MockBundle.cc.

Referenced by clone().


The documentation for this class was generated from the following files:
Generated on Mon Mar 24 11:15:47 2008 for Pydtn Simulator by  doxygen 1.5.4