#include <mac-rx-middle.h>
Public Types | |
typedef Callback< void, Ptr < Packet >, const WifiMacHeader * > | ForwardUpCallback |
Public Member Functions | |
void | Receive (Ptr< Packet > packet, const WifiMacHeader *hdr) |
void | SetForwardCallback (ForwardUpCallback callback) |
Private Types | |
typedef std::map< Mac48Address, OriginatorRxStatus *, std::less< Mac48Address > > | Originators |
typedef std::map< Mac48Address, OriginatorRxStatus *, std::less< Mac48Address > >::iterator | OriginatorsI |
typedef std::map< std::pair < Mac48Address, uint8_t > , OriginatorRxStatus *, std::less< std::pair < Mac48Address, uint8_t > > > | QosOriginators |
typedef std::map< std::pair < Mac48Address, uint8_t > , OriginatorRxStatus *, std::less< std::pair < Mac48Address, uint8_t > > >::iterator | QosOriginatorsI |
Private Member Functions | |
Ptr< Packet > | HandleFragments (Ptr< Packet > packet, const WifiMacHeader *hdr, OriginatorRxStatus *originator) |
bool | IsDuplicate (const WifiMacHeader *hdr, OriginatorRxStatus *originator) const |
OriginatorRxStatus * | Lookup (const WifiMacHeader *hdr) |
Private Attributes | |
ForwardUpCallback | m_callback |
Originators | m_originatorStatus |
QosOriginators | m_qosOriginatorStatus |
Friends | |
class | MacRxMiddleTest |
This class handles duplicate detection and recomposition of fragments.
Definition at line 40 of file mac-rx-middle.h.
void ns3::MacRxMiddle::Receive | ( | Ptr< Packet > | packet, |
const WifiMacHeader * | hdr | ||
) |
The check below is really uneeded because it can fail in a lot of normal cases. Specifically, it is possible for sequence numbers to loop back to zero once they reach 0xfff0 and to go up to 0xf7f0 in which case the check below will report the two sequence numbers to not have the correct order relationship. So, this check cannot be used to discard old duplicate frames. It is thus here only for documentation purposes.
Definition at line 246 of file mac-rx-middle.cc.
References ns3::Mac48Address::IsGroup(), NS_ASSERT, NS_LOG_DEBUG, and NS_LOG_FUNCTION.