A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
ap-wifi-mac.h
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2006, 2009 INRIA
4
* Copyright (c) 2009 MIRKO BANCHI
5
*
6
* This program is free software; you can redistribute it and/or modify
7
* it under the terms of the GNU General Public License version 2 as
8
* published by the Free Software Foundation;
9
*
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
14
*
15
* You should have received a copy of the GNU General Public License
16
* along with this program; if not, write to the Free Software
17
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18
*
19
* Author: Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
20
* Author: Mirko Banchi <mk.banchi@gmail.com>
21
*/
22
#ifndef AP_WIFI_MAC_H
23
#define AP_WIFI_MAC_H
24
25
#include "
regular-wifi-mac.h
"
26
27
#include "
amsdu-subframe-header.h
"
28
#include "
supported-rates.h
"
29
30
namespace
ns3 {
31
39
class
ApWifiMac
:
public
RegularWifiMac
40
{
41
public
:
42
static
TypeId
GetTypeId
(
void
);
43
44
ApWifiMac
();
45
virtual
~ApWifiMac
();
46
50
virtual
void
SetWifiRemoteStationManager
(
Ptr<WifiRemoteStationManager>
stationManager);
51
55
virtual
void
SetLinkUpCallback
(
Callback<void>
linkUp);
56
65
virtual
void
Enqueue
(
Ptr<const Packet>
packet,
Mac48Address
to);
66
78
virtual
void
Enqueue
(
Ptr<const Packet>
packet,
Mac48Address
to,
Mac48Address
from);
79
virtual
bool
SupportsSendFrom
(
void
)
const
;
80
84
virtual
void
SetAddress
(
Mac48Address
address);
88
void
SetBeaconInterval
(
Time
interval);
92
Time
GetBeaconInterval
(
void
)
const
;
96
void
StartBeaconing
(
void
);
97
98
private
:
99
virtual
void
Receive
(
Ptr<Packet>
packet,
const
WifiMacHeader
*hdr);
100
virtual
void
TxOk
(
const
WifiMacHeader
&hdr);
101
virtual
void
TxFailed
(
const
WifiMacHeader
&hdr);
102
112
virtual
void
DeaggregateAmsduAndForward
(
Ptr<Packet>
aggregatedPacket,
113
const
WifiMacHeader
*hdr);
114
115
void
ForwardDown
(
Ptr<const Packet>
packet,
Mac48Address
from,
Mac48Address
to);
116
void
ForwardDown
(
Ptr<const Packet>
packet,
Mac48Address
from,
Mac48Address
to, uint8_t tid);
117
void
SendProbeResp
(
Mac48Address
to);
118
void
SendAssocResp
(
Mac48Address
to,
bool
success);
119
void
SendOneBeacon
(
void
);
120
SupportedRates
GetSupportedRates
(
void
)
const
;
121
void
SetBeaconGeneration
(
bool
enable);
122
bool
GetBeaconGeneration
(
void
)
const
;
123
virtual
void
DoDispose
(
void
);
124
virtual
void
DoStart
(
void
);
125
126
Ptr<DcaTxop>
m_beaconDca
;
127
Time
m_beaconInterval
;
128
bool
m_enableBeaconGeneration
;
129
EventId
m_beaconEvent
;
130
};
131
132
}
// namespace ns3
133
134
#endif
/* AP_WIFI_MAC_H */
src
wifi
model
ap-wifi-mac.h
Generated on Fri Dec 21 2012 19:00:48 for ns-3 by
1.8.1.2