DTN::Route Class Reference

Abstract base class for DTN routes. More...

#include <dtn/Route.h>

Inheritance diagram for DTN::Route:

Inheritance graph
[legend]
Collaboration diagram for DTN::Route:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 Route (Link *l)
 Constructor.
virtual ~Route ()
 Virtual destructor.
virtual bool matches (const Bundle &b) const =0
 Test the appropriateness of this route for a Bundle.
Linklink () const
 The Link held by this route.

Protected Member Functions

 Route ()
 Default constructor (disabled).

Protected Attributes

Linkm_link
 The Link held by this route.


Detailed Description

Abstract base class for DTN routes.

This defines a simple interface of a Link and a method to determine if a particular bundle can be reasonably sent along that Link.

Definition at line 46 of file Route.h.


Constructor & Destructor Documentation

Route::Route ( Link l  ) 

Constructor.

This class does not take ownership of the link.

Parameters:
l The outgoing link for this route

Definition at line 36 of file Route.cc.


Member Function Documentation

virtual bool DTN::Route::matches ( const Bundle b  )  const [pure virtual]

Test the appropriateness of this route for a Bundle.

In general, this will depend on the specific subtype of Route. For example, a prefix routing algorithm will look at the Bundle's destination and see if the route is configured with a prefix of that destination.

Parameters:
b A bundle to forward
Returns:
whether this route is appropriate for b

Implemented in DTN::ExplicitRoute, and DTN::PrefixRoute.


Member Data Documentation

Link* DTN::Route::m_link [protected]

The Link held by this route.

This class does not take ownership of the Link.

Definition at line 77 of file Route.h.

Referenced by link().


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