20 #include "ns3/assert.h"
33 .SetGroupName (
"Wave")
67 std::vector<uint32_t> schs;
68 schs.push_back (
SCH1);
69 schs.push_back (
SCH2);
70 schs.push_back (
SCH3);
71 schs.push_back (
SCH4);
72 schs.push_back (
SCH5);
73 schs.push_back (
SCH6);
81 std::vector<uint32_t> channels;
82 channels.push_back (
CCH);
83 channels.push_back (
SCH1);
84 channels.push_back (
SCH2);
85 channels.push_back (
SCH3);
86 channels.push_back (
SCH4);
87 channels.push_back (
SCH5);
88 channels.push_back (
SCH6);
97 return NumberOfWaveChannels;
104 return channelNumber ==
CCH;
111 if (channelNumber < SCH1 || channelNumber >
SCH6)
115 if (channelNumber % 2 == 1)
119 return (channelNumber !=
CCH);
126 if (channelNumber < SCH1 || channelNumber >
SCH6)
130 if (channelNumber % 2 == 1)
141 return m_channels[channelNumber]->operatingClass;
169 return m_channels[channelNumber]->txPowerLevel;
176 std::map<uint32_t, WaveChannel *> ::iterator i;
manage 7 WaveChannels and the tx information such as data rate and txPowerLevel.
static bool IsCch(uint32_t channelNumber)
static uint32_t GetNumberOfWaveChannels(void)
bool GetManagementAdaptable(uint32_t channelNumber)
static std::vector< uint32_t > GetWaveChannels(void)
virtual void DoDispose(void)
Destructor implementation.
virtual ~ChannelManager()
static TypeId GetTypeId(void)
Get the type ID.
WifiPreamble GetManagementPreamble(uint32_t channelNumber)
uint32_t GetManagementPowerLevel(uint32_t channelNumber)
WifiMode GetManagementDataRate(uint32_t channelNumber)
static bool IsSch(uint32_t channelNumber)
uint32_t GetOperatingClass(uint32_t channelNumber)
std::map< uint32_t, WaveChannel * > m_channels
list of channels
static std::vector< uint32_t > GetSchs(void)
static uint32_t GetCch(void)
static bool IsWaveChannel(uint32_t channelNumber)
A base class which provides memory management and object aggregation.
a unique identifier for an interface.
TypeId SetParent(TypeId tid)
Set the parent TypeId.
represent a single transmission mode
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
#define NS_LOG_FUNCTION_NOARGS()
Output the name of the function.
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by ",...
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
WifiPreamble
The type of preamble to be used by an IEEE 802.11 transmission.
Every class exported by the ns3 library is enclosed in the ns3 namespace.