IBR-DTN
1.0.0
|
#include <NeighborDatabase.h>
Classes | |
class | AlreadyInTransitException |
class | BloomfilterNotAvailableException |
class | DatasetNotAvailableException |
class | EntryNotFoundException |
class | NeighborEntry |
class | NoMoreTransfersAvailable |
class | NoRouteKnownException |
Public Member Functions | |
NeighborDatabase () | |
virtual | ~NeighborDatabase () |
NeighborDatabase::NeighborEntry & | get (const dtn::data::EID &eid, bool noCached=false) throw (EntryNotFoundException) |
NeighborDatabase::NeighborEntry & | create (const dtn::data::EID &eid) throw () |
void | remove (const dtn::data::EID &eid) |
void | expire (const dtn::data::Timestamp ×tamp) |
The neighbor database contains collected information about neighbors. This includes the last timestamp on which a neighbor was seen, the bundles this neighbors has received (bloomfilter with age).
Definition at line 45 of file NeighborDatabase.h.
dtn::routing::NeighborDatabase::NeighborDatabase | ( | ) |
Definition at line 192 of file NeighborDatabase.cpp.
|
virtual |
Definition at line 196 of file NeighborDatabase.cpp.
NeighborDatabase::NeighborEntry & dtn::routing::NeighborDatabase::create | ( | const dtn::data::EID & | eid | ) | |
throw | ( | ||||
) |
Query a neighbor entry of the database. If the entry does not exists, a new entry is created and returned.
eid | The EID of the neighbor. |
Definition at line 207 of file NeighborDatabase.cpp.
void dtn::routing::NeighborDatabase::expire | ( | const dtn::data::Timestamp & | timestamp | ) |
trigger expire mechanisms for bloomfilter and bundle summary
timestamp |
Definition at line 132 of file NeighborDatabase.cpp.
References dtn::routing::NeighborDatabase::NeighborEntry::expire(), and dtn::routing::NeighborDatabase::NeighborEntry::isExpired().
NeighborDatabase::NeighborEntry & dtn::routing::NeighborDatabase::get | ( | const dtn::data::EID & | eid, |
bool | noCached = false |
||
) | |||
throw | ( | EntryNotFoundException | |
) |
Query a neighbor entry of the database. It throws an exception if the neighbor is not available.
eid | The EID of the neighbor |
noCached | Only returns an entry if the neighbor is available |
Definition at line 223 of file NeighborDatabase.cpp.
References dtn::core::BundleCore::getInstance().
Referenced by dtn::routing::NodeHandshakeExtension::processHandshake(), dtn::routing::ProphetRoutingExtension::processHandshake(), dtn::routing::NeighborRoutingExtension::run(), dtn::routing::FloodRoutingExtension::run(), dtn::routing::StaticRoutingExtension::run(), and dtn::routing::EpidemicRoutingExtension::run().
void dtn::routing::NeighborDatabase::remove | ( | const dtn::data::EID & | eid | ) |
Remove an entry of the database.
eid | The EID of the neighbor to remove. |
Definition at line 240 of file NeighborDatabase.cpp.