IBR-DTNSuite
0.8
|
Set of Acknowledgements, that can be serialized in node handshakes. More...
#include <ProphetRoutingExtension.h>
Public Member Functions | |
AcknowledgementSet () | |
AcknowledgementSet (const AcknowledgementSet &) | |
void | insert (const Acknowledgement &) |
Insert an Acknowledgement into the set. | |
void | purge () |
purge the set, i.e. remove acknowledgements that have expired | |
void | merge (const AcknowledgementSet &) |
merge the set with a second AcknowledgementSet | |
bool | has (const dtn::data::BundleID &bundle) const |
check if an acknowledgement exists for the bundle | |
virtual size_t | getIdentifier () const |
virtual size_t | getLength () const |
virtual std::ostream & | serialize (std::ostream &stream) const |
virtual std::istream & | deserialize (std::istream &stream) |
Static Public Attributes | |
static const size_t | identifier = NodeHandshakeItem::PROPHET_ACKNOWLEDGEMENT_SET |
Friends | |
std::ostream & | operator<< (ostream &, const AcknowledgementSet &) |
Set of Acknowledgements, that can be serialized in node handshakes.
Definition at line 106 of file ProphetRoutingExtension.h.
Definition at line 754 of file ProphetRoutingExtension.cpp.
dtn::routing::ProphetRoutingExtension::AcknowledgementSet::AcknowledgementSet | ( | const AcknowledgementSet & | other | ) |
Definition at line 758 of file ProphetRoutingExtension.cpp.
std::istream & dtn::routing::ProphetRoutingExtension::AcknowledgementSet::deserialize | ( | std::istream & | stream | ) | [virtual] |
Implements dtn::routing::NodeHandshakeItem.
Definition at line 816 of file ProphetRoutingExtension.cpp.
References dtn::routing::ProphetRoutingExtension::Acknowledgement::deserialize().
size_t dtn::routing::ProphetRoutingExtension::AcknowledgementSet::getIdentifier | ( | ) | const [virtual] |
Implements dtn::routing::NodeHandshakeItem.
Definition at line 794 of file ProphetRoutingExtension.cpp.
size_t dtn::routing::ProphetRoutingExtension::AcknowledgementSet::getLength | ( | ) | const [virtual] |
Implements dtn::routing::NodeHandshakeItem.
Definition at line 798 of file ProphetRoutingExtension.cpp.
bool dtn::routing::ProphetRoutingExtension::AcknowledgementSet::has | ( | const dtn::data::BundleID & | bundle | ) | const |
check if an acknowledgement exists for the bundle
Definition at line 789 of file ProphetRoutingExtension.cpp.
void dtn::routing::ProphetRoutingExtension::AcknowledgementSet::insert | ( | const Acknowledgement & | ack | ) |
Insert an Acknowledgement into the set.
Definition at line 763 of file ProphetRoutingExtension.cpp.
Referenced by dtn::routing::ProphetRoutingExtension::notify().
void dtn::routing::ProphetRoutingExtension::AcknowledgementSet::merge | ( | const AcknowledgementSet & | other | ) |
merge the set with a second AcknowledgementSet
Definition at line 780 of file ProphetRoutingExtension.cpp.
Referenced by dtn::routing::ProphetRoutingExtension::processHandshake().
purge the set, i.e. remove acknowledgements that have expired
Definition at line 768 of file ProphetRoutingExtension.cpp.
References dtn::utils::Clock::isExpired().
Referenced by dtn::routing::ProphetRoutingExtension::notify(), and dtn::routing::ProphetRoutingExtension::responseHandshake().
std::ostream & dtn::routing::ProphetRoutingExtension::AcknowledgementSet::serialize | ( | std::ostream & | stream | ) | const [virtual] |
Implements dtn::routing::NodeHandshakeItem.
Definition at line 805 of file ProphetRoutingExtension.cpp.
std::ostream& operator<< | ( | ostream & | , |
const AcknowledgementSet & | |||
) | [friend] |
const size_t dtn::routing::ProphetRoutingExtension::AcknowledgementSet::identifier = NodeHandshakeItem::PROPHET_ACKNOWLEDGEMENT_SET [static] |
Definition at line 122 of file ProphetRoutingExtension.h.
Referenced by dtn::routing::ProphetRoutingExtension::requestHandshake(), and dtn::routing::ProphetRoutingExtension::responseHandshake().