DifferentialForwarding::DFPolicy Class Reference

Forwarding policy based on a differential metric. More...

#include <differential_forwarding/DFPolicy.h>

Inheritance diagram for DifferentialForwarding::DFPolicy:

Inheritance graph
[legend]
Collaboration diagram for DifferentialForwarding::DFPolicy:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 DFPolicy (DTN::Node *owner, DTN::Link *link, DFApp *app)
 Contructor.
virtual ~DFPolicy ()
 Virtual destructor.
bool forward (DTN::Bundle *b)
 Attepmt to forward a Bundle.
DTN::BundleforwardOn (const DTN::Link &l)
 Attepmt to forward along a Link that has become available.


Detailed Description

Forwarding policy based on a differential metric.

Definition at line 45 of file DFPolicy.h.


Constructor & Destructor Documentation

DFPolicy::DFPolicy ( DTN::Node owner,
DTN::Link link,
DFApp app 
)

Contructor.

Parameters:
owner The node for which this is the forwarding policy
link The actual link over which data will be sent
app The forwarding algorithm

Definition at line 38 of file DFPolicy.cc.


Member Function Documentation

bool DFPolicy::forward ( DTN::Bundle b  )  [virtual]

Attepmt to forward a Bundle.

Concrete derived classes must implement this.

Parameters:
b A Bundle to forward
Return values:
true b was forwarded
false b was not forwarded and should be considered for local storage

Implements DTN::ForwardingPolicy.

Definition at line 50 of file DFPolicy.cc.

References DTN::Link::available(), DTN::Bundle::destination(), DTN::Bundle::kACK, DTN::Bundle::kBcast, DifferentialForwarding::DFApp::linked(), DTN::NodePolicy::m_owner, and DTN::Bundle::type().

DTN::Bundle * DFPolicy::forwardOn ( const DTN::Link l  )  [virtual]

Attepmt to forward along a Link that has become available.

Concrete derived classes must implement this.

Parameters:
l A Link capable of transmitting a new Bundle
Returns:
a Bundle to forward

Implements DTN::ForwardingPolicy.

Definition at line 83 of file DFPolicy.cc.

References DTN::Bundle::destination(), DTN::BundlePointer::isNull(), DTN::Bundle::kACK, DTN::Bundle::kBcast, DifferentialForwarding::DFApp::linked(), DTN::NodePolicy::m_owner, DTN::BundlePointer::next(), DTN::BundlePointer::repr(), and DTN::Bundle::type().


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