Helper to keep track an outgoing pending Interest.
More...
#include <packet-handler.hpp>
|
| OutgoingPendingInterest (PacketHandler *ph) |
|
template<typename Packet , typename... Arg> |
bool | send (const Packet &interest, int timeout, Arg &&... arg) |
| Send an Interest. More...
|
|
template<typename Packet > |
bool | send (const Packet &interest) |
|
template<typename Packet , typename ArgFirst , typename... Arg, typename = typename std::enable_if<!std::is_integral<ArgFirst>::value>::type> |
bool | send (const Packet &interest, ArgFirst &&arg1, Arg &&... arg) |
|
bool | matchPitToken () const |
| Compare PIT token of current incoming packet against last outgoing Interest. More...
|
|
bool | match (const Data &data, const Interest &interest) const |
| Check Interest-Data match. More...
|
|
bool | match (const Data &data, const Name &name, bool canBePrefix=true) const |
| Check Interest-Data match. More...
|
|
void | expireNow () |
| Set expire time to now. More...
|
|
bool | expired () const |
| Determine if the pending Interest has expired / timed out. More...
|
|
Helper to keep track an outgoing pending Interest.
◆ OutgoingPendingInterest()
ndnph::PacketHandler::OutgoingPendingInterest::OutgoingPendingInterest |
( |
PacketHandler * |
ph | ) |
|
|
inline |
◆ expired()
bool ndnph::PacketHandler::OutgoingPendingInterest::expired |
( |
| ) |
const |
|
inline |
Determine if the pending Interest has expired / timed out.
◆ expireNow()
void ndnph::PacketHandler::OutgoingPendingInterest::expireNow |
( |
| ) |
|
|
inline |
◆ match() [1/2]
bool ndnph::PacketHandler::OutgoingPendingInterest::match |
( |
const Data & |
data, |
|
|
const Interest & |
interest |
|
) |
| const |
|
inline |
Check Interest-Data match.
- Precondition
- processData is executing.
- Parameters
-
data | incoming Data. |
interest | saved outgoing Interest. |
◆ match() [2/2]
bool ndnph::PacketHandler::OutgoingPendingInterest::match |
( |
const Data & |
data, |
|
|
const Name & |
name, |
|
|
bool |
canBePrefix = true |
|
) |
| const |
|
inline |
Check Interest-Data match.
- Precondition
- processData is executing.
- Parameters
-
data | incoming Data. |
name | saved outgoing Interest name. |
canBePrefix | CanBePrefix flag on the Interest. |
◆ matchPitToken()
bool ndnph::PacketHandler::OutgoingPendingInterest::matchPitToken |
( |
| ) |
const |
|
inline |
Compare PIT token of current incoming packet against last outgoing Interest.
- Precondition
- one of processInterest, processData, or processNack is executing.
Comparing PIT token alone is unreliable because PIT token is not guaranteed to be unique. If the application has saved a copy of the outgoing Interest or its name, it's recommended to use match()
instead.
◆ send() [1/3]
template<typename Packet >
bool ndnph::PacketHandler::OutgoingPendingInterest::send |
( |
const Packet & |
interest | ) |
|
|
inline |
◆ send() [2/3]
template<typename Packet , typename ArgFirst , typename... Arg, typename = typename std::enable_if<!std::is_integral<ArgFirst>::value>::type>
bool ndnph::PacketHandler::OutgoingPendingInterest::send |
( |
const Packet & |
interest, |
|
|
ArgFirst && |
arg1, |
|
|
Arg &&... |
arg |
|
) |
| |
|
inline |
◆ send() [3/3]
template<typename Packet , typename... Arg>
bool ndnph::PacketHandler::OutgoingPendingInterest::send |
( |
const Packet & |
interest, |
|
|
int |
timeout, |
|
|
Arg &&... |
arg |
|
) |
| |
|
inline |
Send an Interest.
- Template Parameters
-
Packet | Interest or its parameterized / signed variant. |
- Parameters
-
interest | the Interest. |
timeout | timeout in milliseconds. Default is InterestLifetime. |
arg | other arguments to PacketHandler::send() . |
The documentation for this class was generated from the following file: