INET Framework for OMNeT++/OMNEST
inet::ieee80211::QoSRtsPolicy Class Reference

#include <QoSRtsPolicy.h>

Inheritance diagram for inet::ieee80211::QoSRtsPolicy:
inet::ieee80211::ModeSetListener inet::ieee80211::IRtsPolicy

Public Member Functions

virtual bool isRtsNeeded (Ieee80211Frame *protectedFrame) const override
 
virtual simtime_t getCtsTimeout (Ieee80211RTSFrame *rtsFrame) const override
 
virtual int getRtsThreshold () const override
 
- Public Member Functions inherited from inet::ieee80211::IRtsPolicy
virtual ~IRtsPolicy ()
 

Protected Member Functions

virtual int numInitStages () const override
 
virtual void initialize (int stage) override
 
- Protected Member Functions inherited from inet::ieee80211::ModeSetListener
virtual void receiveSignal (cComponent *source, simsignal_t signalID, cObject *obj, cObject *details) override
 

Protected Attributes

IQoSRateSelectionrateSelection = nullptr
 
int rtsThreshold = -1
 
simtime_t ctsTimeout = -1
 
- Protected Attributes inherited from inet::ieee80211::ModeSetListener
Ieee80211ModeSetmodeSet = nullptr
 

Member Function Documentation

simtime_t inet::ieee80211::QoSRtsPolicy::getCtsTimeout ( Ieee80211RTSFrame rtsFrame) const
overridevirtual

Implements inet::ieee80211::IRtsPolicy.

64 {
66 }
simtime_t getSlotTime() const
Definition: Ieee80211ModeSet.h:78
IQoSRateSelection * rateSelection
Definition: QoSRtsPolicy.h:31
simtime_t ctsTimeout
Definition: QoSRtsPolicy.h:33
Ieee80211ModeSet * modeSet
Definition: ModeSetListener.h:31
simtime_t getSifsTime() const
Definition: Ieee80211ModeSet.h:77
virtual const simtime_t getPhyRxStartDelay() const =0
virtual const IIeee80211Mode * computeResponseCtsFrameMode(Ieee80211RTSFrame *rtsFrame)=0
virtual int inet::ieee80211::QoSRtsPolicy::getRtsThreshold ( ) const
inlineoverridevirtual

Implements inet::ieee80211::IRtsPolicy.

42 { return rtsThreshold; }
int rtsThreshold
Definition: QoSRtsPolicy.h:32
void inet::ieee80211::QoSRtsPolicy::initialize ( int  stage)
overrideprotectedvirtual

Reimplemented from inet::ieee80211::ModeSetListener.

26 {
28  if (stage == INITSTAGE_LOCAL) {
29  rtsThreshold = par("rtsThreshold");
30  ctsTimeout = par("ctsTimeout");
31  rateSelection = check_and_cast<IQoSRateSelection*>(getModuleByPath(par("rateSelectionModule")));
32  }
33 }
IQoSRateSelection * rateSelection
Definition: QoSRtsPolicy.h:31
Abstract interface for rate selection.
Definition: IQoSRateSelection.h:36
simtime_t ctsTimeout
Definition: QoSRtsPolicy.h:33
Local initializations.
Definition: InitStages.h:35
virtual void initialize(int stage) override
Definition: ModeSetListener.cc:25
int rtsThreshold
Definition: QoSRtsPolicy.h:32
bool inet::ieee80211::QoSRtsPolicy::isRtsNeeded ( Ieee80211Frame protectedFrame) const
overridevirtual

Implements inet::ieee80211::IRtsPolicy.

47 {
48  if (dynamic_cast<Ieee80211BlockAckReq*>(protectedFrame))
49  return false;
50  if (dynamic_cast<Ieee80211DataOrMgmtFrame*>(protectedFrame))
51  return protectedFrame->getByteLength() >= rtsThreshold && !protectedFrame->getReceiverAddress().isMulticast();
52  else
53  return false;
54 }
virtual MACAddress & getReceiverAddress()
bool isMulticast() const
Returns true if this is a multicast logical address (first byte&#39;s lsb is 1).
Definition: MACAddress.h:146
int rtsThreshold
Definition: QoSRtsPolicy.h:32
virtual int inet::ieee80211::QoSRtsPolicy::numInitStages ( ) const
inlineoverrideprotectedvirtual

Reimplemented from inet::ieee80211::ModeSetListener.

36 { return NUM_INIT_STAGES; }
The number of initialization stages.
Definition: InitStages.h:116

Member Data Documentation

simtime_t inet::ieee80211::QoSRtsPolicy::ctsTimeout = -1
protected

Referenced by getCtsTimeout(), and initialize().

IQoSRateSelection* inet::ieee80211::QoSRtsPolicy::rateSelection = nullptr
protected

Referenced by getCtsTimeout(), and initialize().

int inet::ieee80211::QoSRtsPolicy::rtsThreshold = -1
protected

Referenced by initialize(), and isRtsNeeded().


The documentation for this class was generated from the following files: