IBR-DTNSuite
0.8
|
#include <BaseRouter.h>
Definition at line 32 of file BaseRouter.h.
implementation of the BaseRouter class
Definition at line 134 of file BaseRouter.cpp.
References addExtension().
Definition at line 148 of file BaseRouter.cpp.
void dtn::routing::BaseRouter::addExtension | ( | BaseRouter::Extension * | extension | ) |
Add a routing extension to the routing core.
extension |
Definition at line 161 of file BaseRouter.cpp.
Referenced by __daemon_run(), and BaseRouter().
void dtn::routing::BaseRouter::addPurgedBundle | ( | const dtn::data::MetaBundle & | meta | ) |
Add a bundle to the purge vector of this daemon.
meta | The bundle to purge. |
Definition at line 478 of file BaseRouter.cpp.
References dtn::routing::BundleSummary::add().
void dtn::routing::BaseRouter::componentDown | ( | ) | [protected, virtual] |
Implements dtn::daemon::IntegratedComponent.
Definition at line 202 of file BaseRouter.cpp.
References dtn::core::BundleGeneratedEvent::className, dtn::net::BundleReceivedEvent::className, dtn::net::TransferCompletedEvent::className, dtn::routing::RequeueBundleEvent::className, dtn::routing::QueueBundleEvent::className, dtn::core::BundleExpiredEvent::className, dtn::core::TimeEvent::className, dtn::net::ConnectionEvent::className, dtn::net::TransferAbortedEvent::className, dtn::routing::NodeHandshakeEvent::className, dtn::core::NodeEvent::className, dtn::routing::StaticRouteChangeEvent::className, IBRCOMMON_LOGGER, IBRCOMMON_LOGGER_ENDL, ibrcommon::JoinableThread::join(), ibrcommon::JoinableThread::stop(), dtn::core::EventReceiver::unbindEvent(), and ibrcommon::Exception::what().
void dtn::routing::BaseRouter::componentUp | ( | ) | [protected, virtual] |
Implements dtn::daemon::IntegratedComponent.
Definition at line 171 of file BaseRouter.cpp.
References dtn::core::EventReceiver::bindEvent(), dtn::core::BundleGeneratedEvent::className, dtn::net::BundleReceivedEvent::className, dtn::net::TransferCompletedEvent::className, dtn::routing::RequeueBundleEvent::className, dtn::routing::QueueBundleEvent::className, dtn::core::BundleExpiredEvent::className, dtn::core::TimeEvent::className, dtn::net::ConnectionEvent::className, dtn::net::TransferAbortedEvent::className, dtn::routing::NodeHandshakeEvent::className, dtn::core::NodeEvent::className, dtn::routing::StaticRouteChangeEvent::className, IBRCOMMON_LOGGER, IBRCOMMON_LOGGER_ENDL, ibrcommon::JoinableThread::start(), and ibrcommon::Exception::what().
void dtn::routing::BaseRouter::doHandshake | ( | const dtn::data::EID & | eid | ) |
Request a neighbor handshake
eid |
Definition at line 437 of file BaseRouter.cpp.
References dtn::routing::NodeHandshakeExtension::doHandshake().
bool dtn::routing::BaseRouter::filterKnown | ( | const dtn::data::MetaBundle & | meta | ) |
check if a bundle is known if the bundle is unkown add it to the known list and return false
id |
Definition at line 463 of file BaseRouter.cpp.
References dtn::routing::BundleSummary::add(), and dtn::routing::BundleSummary::contains().
Referenced by raiseEvent().
Get a bundle out of the storage.
id | The ID of the bundle. |
Definition at line 432 of file BaseRouter.cpp.
References dtn::storage::BundleStorage::get().
const std::list< BaseRouter::Extension * > & dtn::routing::BaseRouter::getExtensions | ( | ) | const |
const std::string dtn::routing::BaseRouter::getName | ( | ) | const [virtual] |
Implements dtn::daemon::Component.
Definition at line 490 of file BaseRouter.cpp.
Access to the neighbor database. Where several data about the neighbors is stored.
Definition at line 495 of file BaseRouter.cpp.
Get a vector (bloomfilter) of all purged bundles.
Definition at line 484 of file BaseRouter.cpp.
References dtn::routing::BundleSummary::getSummaryVector().
Definition at line 442 of file BaseRouter.cpp.
Get a vector (bloomfilter) of all known bundles.
Definition at line 472 of file BaseRouter.cpp.
References dtn::routing::BundleSummary::getSummaryVector().
bool dtn::routing::BaseRouter::isKnown | ( | const dtn::data::BundleID & | id | ) |
This method returns true, if the given BundleID is known.
id |
Definition at line 454 of file BaseRouter.cpp.
References dtn::routing::BundleSummary::contains().
void dtn::routing::BaseRouter::raiseEvent | ( | const dtn::core::Event * | evt | ) | [virtual] |
method to receive new events from the EventSwitch
Implements dtn::core::EventReceiver.
Definition at line 238 of file BaseRouter.cpp.
References dtn::data::PrimaryBlock::_destination, dtn::routing::BundleSummary::add(), dtn::routing::NeighborDatabase::addBundle(), dtn::core::BundleGeneratedEvent::bundle, dtn::net::BundleReceivedEvent::bundle, dtn::core::BUNDLE_DELETED, dtn::core::BUNDLE_RECEIVED, dtn::routing::NeighborDatabase::create(), dtn::data::StatusReportBlock::DEPLETED_STORAGE, dtn::data::PrimaryBlock::DESTINATION_IS_SINGLETON, dtn::data::BundleList::expire(), dtn::routing::NeighborDatabase::expire(), filterKnown(), dtn::net::BundleReceivedEvent::fromlocal, dtn::storage::BundleStorage::get(), dtn::routing::NeighborDatabase::get(), dtn::security::SecurityManager::getInstance(), dtn::core::TimeEvent::getTimestamp(), IBRCOMMON_LOGGER, IBRCOMMON_LOGGER_ENDL, dtn::utils::Clock::isExpired(), dtn::core::BundleCore::local, dtn::core::NODE_AVAILABLE, dtn::core::NODE_UNAVAILABLE, dtn::net::BundleReceivedEvent::peer, dtn::routing::QueueBundleEvent::raise(), dtn::core::BundleEvent::raise(), dtn::net::TransferAbortedEvent::REASON_REFUSED, dtn::routing::NeighborDatabase::NeighborEntry::releaseTransfer(), dtn::routing::NeighborDatabase::reset(), setKnown(), dtn::storage::BundleStorage::store(), dtn::data::Bundle::toString(), and dtn::security::SecurityManager::verify().
void dtn::routing::BaseRouter::setKnown | ( | const dtn::data::MetaBundle & | meta | ) |
This method add a BundleID to the set of known bundles
id |
Definition at line 447 of file BaseRouter.cpp.
References dtn::routing::BundleSummary::add().
Referenced by raiseEvent().