IBR-DTNSuite
0.8
|
#include <FragmentManager.h>
Classes | |
class | Transmission |
Public Member Functions | |
FragmentManager () | |
virtual | ~FragmentManager () |
void | signal (const dtn::data::MetaBundle &meta) |
void | __cancellation () |
void | componentUp () |
void | componentRun () |
void | componentDown () |
void | raiseEvent (const Event *evt) |
const std::string | getName () const |
Static Public Member Functions | |
static void | setOffset (const dtn::data::EID &peer, const dtn::data::BundleID &id, size_t abs_offset) |
static size_t | getOffset (const dtn::data::EID &peer, const dtn::data::BundleID &id) |
Definition at line 24 of file FragmentManager.h.
Definition at line 27 of file FragmentManager.cpp.
dtn::core::FragmentManager::~FragmentManager | ( | ) | [virtual] |
Definition at line 32 of file FragmentManager.cpp.
void dtn::core::FragmentManager::__cancellation | ( | ) | [virtual] |
Implements dtn::daemon::IndependentComponent.
Definition at line 41 of file FragmentManager.cpp.
References ibrcommon::Queue< T >::abort().
void dtn::core::FragmentManager::componentDown | ( | ) | [virtual] |
Implements dtn::daemon::IndependentComponent.
Definition at line 126 of file FragmentManager.cpp.
References dtn::routing::QueueBundleEvent::className, dtn::core::TimeEvent::className, and dtn::core::EventReceiver::unbindEvent().
void dtn::core::FragmentManager::componentRun | ( | ) | [virtual] |
Implements dtn::daemon::IndependentComponent.
Definition at line 54 of file FragmentManager.cpp.
References dtn::data::MetaBundle::appdatalength, dtn::storage::BundleStorage::get(), dtn::data::BundleMerger::Container::getBundle(), dtn::data::BundleMerger::getContainer(), dtn::core::BundleCore::getInstance(), ibrcommon::Queue< T >::getnpop(), dtn::core::BundleCore::getStorage(), IBRCOMMON_LOGGER, IBRCOMMON_LOGGER_DEBUG, IBRCOMMON_LOGGER_ENDL, dtn::data::BundleMerger::Container::isComplete(), dtn::core::BundleCore::local, dtn::data::BundleID::offset, dtn::data::MetaBundle::payloadlength, dtn::net::BundleReceivedEvent::raise(), dtn::core::BundlePurgeEvent::raise(), and dtn::data::BundleID::toString().
void dtn::core::FragmentManager::componentUp | ( | ) | [virtual] |
Implements dtn::daemon::IndependentComponent.
Definition at line 47 of file FragmentManager.cpp.
References dtn::core::EventReceiver::bindEvent(), dtn::routing::QueueBundleEvent::className, and dtn::core::TimeEvent::className.
const std::string dtn::core::FragmentManager::getName | ( | ) | const [virtual] |
Return an identifier for this component
Implements dtn::daemon::Component.
Definition at line 36 of file FragmentManager.cpp.
size_t dtn::core::FragmentManager::getOffset | ( | const dtn::data::EID & | peer, |
const dtn::data::BundleID & | id | ||
) | [static] |
Get the offset of a transmission
peer | |
id |
Definition at line 222 of file FragmentManager.cpp.
Referenced by dtn::net::operator<<().
void dtn::core::FragmentManager::raiseEvent | ( | const Event * | evt | ) | [virtual] |
Implements dtn::core::EventReceiver.
Definition at line 132 of file FragmentManager.cpp.
References dtn::routing::QueueBundleEvent::bundle, dtn::data::BundleList::expire(), dtn::data::BundleID::fragment, dtn::core::TimeEvent::getTimestamp(), and signal().
void dtn::core::FragmentManager::setOffset | ( | const dtn::data::EID & | peer, |
const dtn::data::BundleID & | id, | ||
size_t | abs_offset | ||
) | [static] |
Updates the offset of a transmission
peer | |
id | |
offset |
Definition at line 200 of file FragmentManager.cpp.
References dtn::storage::BundleStorage::get(), dtn::utils::Clock::getExpireTime(), dtn::core::BundleCore::getInstance(), dtn::core::BundleCore::getStorage(), IBRCOMMON_LOGGER_DEBUG, and IBRCOMMON_LOGGER_ENDL.
Referenced by dtn::net::TCPConnection::clearQueue().
void dtn::core::FragmentManager::signal | ( | const dtn::data::MetaBundle & | meta | ) |
Definition at line 148 of file FragmentManager.cpp.
References dtn::data::MetaBundle::destination, dtn::data::PrimaryBlock::DESTINATION_IS_SINGLETON, dtn::data::MetaBundle::get(), dtn::data::EID::getNode(), dtn::core::BundleCore::local, and ibrcommon::Queue< T >::push().
Referenced by raiseEvent().