A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
src
wifi
model
wifi-spectrum-phy-interface.h
Go to the documentation of this file.
1
/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2009 CTTC
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: Nicola Baldo <nbaldo@cttc.es>
19
*/
20
21
#ifndef WIFI_SPECTRUM_PHY_INTERFACE_H
22
#define WIFI_SPECTRUM_PHY_INTERFACE_H
23
24
#include "ns3/spectrum-phy.h"
25
26
namespace
ns3
{
27
28
class
SpectrumWifiPhy;
29
41
class
WifiSpectrumPhyInterface
:
public
SpectrumPhy
42
{
43
public
:
48
static
TypeId
GetTypeId
(
void
);
49
WifiSpectrumPhyInterface
();
54
void
SetSpectrumWifiPhy
(
const
Ptr<SpectrumWifiPhy>
phy
);
55
56
// Inherited from SpectrumPhy
57
Ptr<NetDevice>
GetDevice
()
const
;
58
void
SetDevice
(
const
Ptr<NetDevice>
d);
59
void
SetMobility
(
const
Ptr<MobilityModel>
m);
60
Ptr<MobilityModel>
GetMobility
();
61
void
SetChannel
(
const
Ptr<SpectrumChannel>
c);
62
Ptr<const SpectrumModel>
GetRxSpectrumModel
()
const
;
63
Ptr<AntennaModel>
GetRxAntenna
();
64
void
StartRx
(
Ptr<SpectrumSignalParameters>
params);
65
66
67
private
:
68
virtual
void
DoDispose
(
void
);
69
Ptr<SpectrumWifiPhy>
m_spectrumWifiPhy
;
70
Ptr<NetDevice>
m_netDevice
;
71
Ptr<SpectrumChannel>
m_channel
;
72
};
73
74
}
// namespace ns3
75
76
#endif
/* WIFI_SPECTRUM_PHY_INTERFACE_H */
ns3::WifiSpectrumPhyInterface::SetDevice
void SetDevice(const Ptr< NetDevice > d)
Set the associated NetDevice instance.
Definition:
wifi-spectrum-phy-interface.cc:75
ns3::Ptr< SpectrumWifiPhy >
ns3::SpectrumPhy
Abstract base class for Spectrum-aware PHY layers.
Definition:
spectrum-phy.h:45
ns3::WifiSpectrumPhyInterface::SetSpectrumWifiPhy
void SetSpectrumWifiPhy(const Ptr< SpectrumWifiPhy > phy)
Connect SpectrumWifiPhy object.
Definition:
wifi-spectrum-phy-interface.cc:57
ns3::WifiSpectrumPhyInterface::GetDevice
Ptr< NetDevice > GetDevice() const
Get the associated NetDevice instance.
Definition:
wifi-spectrum-phy-interface.cc:63
ns3::WifiSpectrumPhyInterface::m_channel
Ptr< SpectrumChannel > m_channel
spectrum channel
Definition:
wifi-spectrum-phy-interface.h:71
ns3::WifiSpectrumPhyInterface::GetTypeId
static TypeId GetTypeId(void)
Get the type ID.
Definition:
wifi-spectrum-phy-interface.cc:35
ns3::WifiSpectrumPhyInterface::StartRx
void StartRx(Ptr< SpectrumSignalParameters > params)
Notify the SpectrumPhy instance of an incoming signal.
Definition:
wifi-spectrum-phy-interface.cc:107
ns3::WifiSpectrumPhyInterface
This class is an adaptor between class SpectrumWifiPhy (which inherits from WifiPhy) and class Spectr...
Definition:
wifi-spectrum-phy-interface.h:41
ns3::WifiSpectrumPhyInterface::WifiSpectrumPhyInterface
WifiSpectrumPhyInterface()
Definition:
wifi-spectrum-phy-interface.cc:43
third.phy
phy
Definition:
third.py:86
ns3::WifiSpectrumPhyInterface::m_netDevice
Ptr< NetDevice > m_netDevice
the device
Definition:
wifi-spectrum-phy-interface.h:70
ns3::WifiSpectrumPhyInterface::GetMobility
Ptr< MobilityModel > GetMobility()
Get the associated MobilityModel instance.
Definition:
wifi-spectrum-phy-interface.cc:69
ns3::WifiSpectrumPhyInterface::DoDispose
virtual void DoDispose(void)
Destructor implementation.
Definition:
wifi-spectrum-phy-interface.cc:49
ns3::WifiSpectrumPhyInterface::SetChannel
void SetChannel(const Ptr< SpectrumChannel > c)
Set the channel attached to this device.
Definition:
wifi-spectrum-phy-interface.cc:87
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::WifiSpectrumPhyInterface::GetRxSpectrumModel
Ptr< const SpectrumModel > GetRxSpectrumModel() const
Definition:
wifi-spectrum-phy-interface.cc:94
ns3::WifiSpectrumPhyInterface::GetRxAntenna
Ptr< AntennaModel > GetRxAntenna()
Get the AntennaModel used by the NetDevice for reception.
Definition:
wifi-spectrum-phy-interface.cc:100
ns3::WifiSpectrumPhyInterface::m_spectrumWifiPhy
Ptr< SpectrumWifiPhy > m_spectrumWifiPhy
spectrum phy
Definition:
wifi-spectrum-phy-interface.h:69
ns3::WifiSpectrumPhyInterface::SetMobility
void SetMobility(const Ptr< MobilityModel > m)
Set the mobility model associated with this device.
Definition:
wifi-spectrum-phy-interface.cc:81
ns3::TypeId
a unique identifier for an interface.
Definition:
type-id.h:58
Generated on Wed Nov 7 2018 10:02:15 for ns-3 by
1.8.14