ns3::Ns2ExtWifiChannel Class Reference

A Ns2Ext wifi channel. More...

#include <ns2ext-wifi-channel.h>

Inheritance diagram for ns3::Ns2ExtWifiChannel:
Inheritance graph
[legend]
Collaboration diagram for ns3::Ns2ExtWifiChannel:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 Ns2ExtWifiChannel ()
virtual ~Ns2ExtWifiChannel ()
virtual uint32_t GetNDevices (void) const
virtual Ptr< NetDeviceGetDevice (uint32_t i) const
void Add (Ptr< Ns2ExtWifiPhy > phy)
void SetPropagationLossModel (Ptr< PropagationLossModel > loss)
void SetPropagationDelayModel (Ptr< PropagationDelayModel > delay)
void Send (Ptr< Ns2ExtWifiPhy > sender, Ptr< const Packet > packet, double txPowerDbm, WifiMode wifiMode, WifiPreamble preamble) const

Static Public Member Functions

static TypeId GetTypeId (void)
 This method returns the TypeId associated to ns3::WifiChannel.

Private Types

typedef std::vector< Ptr
< Ns2ExtWifiPhy > > 
PhyList

Private Member Functions

void Receive (uint32_t i, Ptr< Packet > packet, double rxPowerDbm, WifiMode txMode, WifiPreamble preamble) const

Private Attributes

PhyList m_phyList
Ptr< PropagationLossModelm_loss
Ptr< PropagationDelayModelm_delay

Detailed Description

A Ns2Ext wifi channel.

This wifi channel implements the propagation model described in "Yet Another Network Simulator", (http://cutebugs.net/files/wns2-yans.pdf).

This class is expected to be used in tandem with the ns3::Ns2ExtWifiPhy class and contains a ns3::PropagationLossModel and a ns3::PropagationDelayModel. By default, no propagation models are set so, it is the caller's responsability to set them before using the channel.

Definition at line 49 of file ns2ext-wifi-channel.h.


Member Typedef Documentation

typedef std::vector<Ptr<Ns2ExtWifiPhy> > ns3::Ns2ExtWifiChannel::PhyList [private]

Definition at line 86 of file ns2ext-wifi-channel.h.


Constructor & Destructor Documentation

ns3::Ns2ExtWifiChannel::Ns2ExtWifiChannel (  ) 

Definition at line 56 of file ns2ext-wifi-channel.cc.

ns3::Ns2ExtWifiChannel::~Ns2ExtWifiChannel (  )  [virtual]

Definition at line 58 of file ns2ext-wifi-channel.cc.

References m_phyList.


Member Function Documentation

void ns3::Ns2ExtWifiChannel::Add ( Ptr< Ns2ExtWifiPhy phy  ) 

Definition at line 117 of file ns2ext-wifi-channel.cc.

References m_phyList.

Ptr< NetDevice > ns3::Ns2ExtWifiChannel::GetDevice ( uint32_t  i  )  const [virtual]
Parameters:
i index of NetDevice to retrieve
Returns:
one of the NetDevices connected to this channel.

This method must be implemented by subclasses.

Implements ns3::Channel.

Definition at line 111 of file ns2ext-wifi-channel.cc.

References m_phyList.

uint32_t ns3::Ns2ExtWifiChannel::GetNDevices ( void   )  const [virtual]
Returns:
the number of NetDevices connected to this Channel.

This method must be implemented by subclasses.

Implements ns3::Channel.

Definition at line 106 of file ns2ext-wifi-channel.cc.

References m_phyList.

TypeId ns3::Ns2ExtWifiChannel::GetTypeId ( void   )  [static]

This method returns the TypeId associated to ns3::WifiChannel.

/*! /*! /*! /*! /*!

This object is accessible through the following paths with Config::Set and Config::Connect:

  • /NodeList/[i]/DeviceList/[i]/$ns3WifiNetDevice/Channel

No Attributes defined for this type.
No TraceSources defined for this type.

Reimplemented from ns3::WifiChannel.

Definition at line 39 of file ns2ext-wifi-channel.cc.

References ns3::TypeId::AddAttribute(), m_delay, m_loss, and ns3::TypeId::SetParent().

void ns3::Ns2ExtWifiChannel::Receive ( uint32_t  i,
Ptr< Packet packet,
double  rxPowerDbm,
WifiMode  txMode,
WifiPreamble  preamble 
) const [private]

Definition at line 99 of file ns2ext-wifi-channel.cc.

References m_phyList.

Referenced by Send().

void ns3::Ns2ExtWifiChannel::Send ( Ptr< Ns2ExtWifiPhy sender,
Ptr< const Packet packet,
double  txPowerDbm,
WifiMode  wifiMode,
WifiPreamble  preamble 
) const
Parameters:
sender the device from which the packet is originating.
packet the packet to send
txPowerDbm the tx power associated to the packet
wifiMode the tx mode associated to the packet
preamble the preamble associated to the packet

This method should not be invoked by normal users. It is currently invoked only from WifiPhy::Send.

Definition at line 75 of file ns2ext-wifi-channel.cc.

References m_delay, m_loss, m_phyList, NS_ASSERT, NS_LOG_DEBUG, Receive(), and ns3::Simulator::Schedule().

void ns3::Ns2ExtWifiChannel::SetPropagationDelayModel ( Ptr< PropagationDelayModel delay  ) 
Parameters:
delay the new propagation delay model.

Definition at line 69 of file ns2ext-wifi-channel.cc.

References m_delay.

void ns3::Ns2ExtWifiChannel::SetPropagationLossModel ( Ptr< PropagationLossModel loss  ) 
Parameters:
loss the new propagation loss model.

Definition at line 64 of file ns2ext-wifi-channel.cc.

References m_loss.


Member Data Documentation

Definition at line 93 of file ns2ext-wifi-channel.h.

Referenced by GetTypeId(), Send(), and SetPropagationDelayModel().

Definition at line 92 of file ns2ext-wifi-channel.h.

Referenced by GetTypeId(), Send(), and SetPropagationLossModel().

Definition at line 91 of file ns2ext-wifi-channel.h.

Referenced by Add(), GetDevice(), GetNDevices(), Receive(), Send(), and ~Ns2ExtWifiChannel().


The documentation for this class was generated from the following files:
Generated on Thu Dec 3 14:11:15 2009 for NS-3 by  doxygen 1.6.3