A Discrete-Event Network Simulator
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
constant-rate-wifi-manager.cc
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2004,2005 INRIA
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License version 2 as
7  * published by the Free Software Foundation;
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  *
18  * Author: Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
19  */
20 
22 
23 #include "ns3/string.h"
24 #include "ns3/assert.h"
25 #include "ns3/log.h"
26 
27 NS_LOG_COMPONENT_DEFINE ("ConstantRateWifiManager");
28 
29 namespace ns3 {
30 
31 NS_OBJECT_ENSURE_REGISTERED (ConstantRateWifiManager);
32 
33 TypeId
35 {
36  static TypeId tid = TypeId ("ns3::ConstantRateWifiManager")
38  .AddConstructor<ConstantRateWifiManager> ()
39  .AddAttribute ("DataMode", "The transmission mode to use for every data packet transmission",
40  StringValue ("OfdmRate6Mbps"),
41  MakeWifiModeAccessor (&ConstantRateWifiManager::m_dataMode),
42  MakeWifiModeChecker ())
43  .AddAttribute ("ControlMode", "The transmission mode to use for every control packet transmission.",
44  StringValue ("OfdmRate6Mbps"),
45  MakeWifiModeAccessor (&ConstantRateWifiManager::m_ctlMode),
46  MakeWifiModeChecker ())
47  ;
48  return tid;
49 }
50 
52 {
53  NS_LOG_FUNCTION (this);
54 }
56 {
57  NS_LOG_FUNCTION (this);
58 }
59 
60 
63 {
64  NS_LOG_FUNCTION (this);
65  WifiRemoteStation *station = new WifiRemoteStation ();
66  return station;
67 }
68 
69 
70 void
72  double rxSnr, WifiMode txMode)
73 {
74  NS_LOG_FUNCTION (this << station << rxSnr << txMode);
75 }
76 void
78 {
79  NS_LOG_FUNCTION (this << station);
80 }
81 void
83 {
84  NS_LOG_FUNCTION (this << station);
85 }
86 void
88  double ctsSnr, WifiMode ctsMode, double rtsSnr)
89 {
90  NS_LOG_FUNCTION (this << st << ctsSnr << ctsMode << rtsSnr);
91 }
92 void
94  double ackSnr, WifiMode ackMode, double dataSnr)
95 {
96  NS_LOG_FUNCTION (this << st << ackSnr << ackMode << dataSnr);
97 }
98 void
100 {
101  NS_LOG_FUNCTION (this << station);
102 }
103 void
105 {
106  NS_LOG_FUNCTION (this << station);
107 }
108 
109 WifiMode
111 {
112  NS_LOG_FUNCTION (this << st << size);
113  return m_dataMode;
114 }
115 WifiMode
117 {
118  NS_LOG_FUNCTION (this << st);
119  return m_ctlMode;
120 }
121 
122 bool
124 {
125  NS_LOG_FUNCTION (this);
126  return true;
127 }
128 
129 } // namespace ns3