|
IBR-DTNSuite
0.10
|
This class keeps track of the predictablities to see a specific EID. More...
#include <DeliveryPredictabilityMap.h>


Classes | |
| class | ValueNotFoundException |
Public Member Functions | |
| DeliveryPredictabilityMap () | |
| DeliveryPredictabilityMap (const size_t &time_unit, const float &beta, const float &gamma) | |
| virtual | ~DeliveryPredictabilityMap () |
| virtual const dtn::data::Number & | getIdentifier () const |
| virtual dtn::data::Length | getLength () const |
| virtual std::ostream & | serialize (std::ostream &stream) const |
| virtual std::istream & | deserialize (std::istream &stream) |
| float | get (const dtn::data::EID &neighbor) const throw (ValueNotFoundException) |
| void | set (const dtn::data::EID &neighbor, float value) |
| void | clear () |
| void | update (const dtn::data::EID &origin, const DeliveryPredictabilityMap &dpm, const float &p_encounter_first) |
| void | age (const float &p_first_threshold) |
| void | toString (std::ostream &stream) const |
Public Member Functions inherited from dtn::routing::NeighborDataSetImpl | |
| NeighborDataSetImpl (const dtn::data::Number &id) | |
| virtual | ~NeighborDataSetImpl ()=0 |
Public Member Functions inherited from dtn::routing::NodeHandshakeItem | |
| virtual | ~NodeHandshakeItem () |
Public Member Functions inherited from ibrcommon::Mutex | |
| Mutex (MUTEX_TYPE type=MUTEX_NORMAL) | |
| virtual | ~Mutex () |
| virtual void | trylock () throw (MutexException) |
| virtual void | enter () throw (MutexException) |
| virtual void | leave () throw (MutexException) |
Public Member Functions inherited from ibrcommon::MutexInterface | |
| virtual | ~MutexInterface ()=0 |
Static Public Attributes | |
| static const dtn::data::Number | identifier = NodeHandshakeItem::DELIVERY_PREDICTABILITY_MAP |
Friends | |
| std::ostream & | operator<< (std::ostream &stream, const DeliveryPredictabilityMap &map) |
Additional Inherited Members | |
Public Types inherited from dtn::routing::NodeHandshakeItem | |
| enum | IDENTIFIER { BLOOM_FILTER_SUMMARY_VECTOR = 1, BLOOM_FILTER_PURGE_VECTOR = 2, DELIVERY_PREDICTABILITY_MAP = 3, PROPHET_ACKNOWLEDGEMENT_SET = 4 } |
Public Types inherited from ibrcommon::Mutex | |
| enum | MUTEX_TYPE { MUTEX_NORMAL = PTHREAD_MUTEX_NORMAL, MUTEX_RECURSIVE = PTHREAD_MUTEX_RECURSIVE, MUTEX_ERRORCHECK = PTHREAD_MUTEX_ERRORCHECK } |
Static Public Member Functions inherited from ibrcommon::Mutex | |
| static MutexInterface & | dummy () |
Public Attributes inherited from dtn::routing::NeighborDataSetImpl | |
| const dtn::data::Number | _dataset_id |
Protected Attributes inherited from ibrcommon::Mutex | |
| pthread_mutex_t | m_mutex |
| pthread_mutexattr_t | m_attr |
This class keeps track of the predictablities to see a specific EID.
This class can be used as a map from EID to float. Also, it can be serialized as a NodeHandshakeItem to be exchanged with neighbors.
Definition at line 27 of file DeliveryPredictabilityMap.h.
| dtn::routing::DeliveryPredictabilityMap::DeliveryPredictabilityMap | ( | ) |
Definition at line 20 of file DeliveryPredictabilityMap.cpp.
| dtn::routing::DeliveryPredictabilityMap::DeliveryPredictabilityMap | ( | const size_t & | time_unit, |
| const float & | beta, | ||
| const float & | gamma | ||
| ) |
Definition at line 25 of file DeliveryPredictabilityMap.cpp.
|
virtual |
Definition at line 30 of file DeliveryPredictabilityMap.cpp.
| void dtn::routing::DeliveryPredictabilityMap::age | ( | const float & | p_first_threshold | ) |
Age all entries in the DeliveryPredictabilityMap.
Definition at line 190 of file DeliveryPredictabilityMap.cpp.
References dtn::data::SDNV< E >::get(), dtn::utils::Clock::getUnixTimestamp(), and dtn::core::BundleCore::local.

| void dtn::routing::DeliveryPredictabilityMap::clear | ( | ) |
Definition at line 154 of file DeliveryPredictabilityMap.cpp.
|
virtual |
Implements dtn::routing::NodeHandshakeItem.
Definition at line 80 of file DeliveryPredictabilityMap.cpp.
References IBRCOMMON_LOGGER_DEBUG_TAG, and IBRCOMMON_LOGGER_ENDL.
| float dtn::routing::DeliveryPredictabilityMap::get | ( | const dtn::data::EID & | neighbor | ) | const throw (ValueNotFoundException) |
Definition at line 138 of file DeliveryPredictabilityMap.cpp.
Referenced by dtn::routing::ForwardingStrategy::neighborDPIsGreater().
|
virtual |
Implements dtn::routing::NodeHandshakeItem.
Definition at line 33 of file DeliveryPredictabilityMap.cpp.
References identifier.
|
virtual |
Implements dtn::routing::NodeHandshakeItem.
Definition at line 38 of file DeliveryPredictabilityMap.cpp.
References dtn::data::SDNV< E >::getLength().

|
virtual |
Implements dtn::routing::NodeHandshakeItem.
Definition at line 59 of file DeliveryPredictabilityMap.cpp.
References IBRCOMMON_LOGGER_DEBUG_TAG, and IBRCOMMON_LOGGER_ENDL.
| void dtn::routing::DeliveryPredictabilityMap::set | ( | const dtn::data::EID & | neighbor, |
| float | value | ||
| ) |
Definition at line 149 of file DeliveryPredictabilityMap.cpp.
Referenced by dtn::routing::ProphetRoutingExtension::ProphetRoutingExtension().
| void dtn::routing::DeliveryPredictabilityMap::toString | ( | std::ostream & | stream | ) | const |
Print out the content as readable text.
Definition at line 221 of file DeliveryPredictabilityMap.cpp.
Referenced by dtn::routing::operator<<().
| void dtn::routing::DeliveryPredictabilityMap::update | ( | const dtn::data::EID & | origin, |
| const DeliveryPredictabilityMap & | dpm, | ||
| const float & | p_encounter_first | ||
| ) |
Updates the DeliveryPredictabilityMap with one recieved by a neighbor.
| dpm | the DeliveryPredictabilityMap recieved from the neighbor |
Calculate transitive values
Definition at line 159 of file DeliveryPredictabilityMap.cpp.
References dtn::core::BundleCore::local.
Referenced by dtn::routing::ProphetRoutingExtension::processHandshake().
|
friend |
Definition at line 230 of file DeliveryPredictabilityMap.cpp.
|
static |
Definition at line 29 of file DeliveryPredictabilityMap.h.
Referenced by getIdentifier(), dtn::routing::ProphetRoutingExtension::requestHandshake(), and dtn::routing::ProphetRoutingExtension::responseHandshake().