A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
src
mesh
model
dot11s
airtime-metric.h
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2009 IITP RAS
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
* Authors: Kirill Andreev <andreev@iitp.ru>
19
*/
20
21
#ifndef AIRTIME_METRIC_H
22
#define AIRTIME_METRIC_H
23
#include "ns3/mesh-wifi-interface-mac.h"
24
namespace
ns3
{
25
namespace
dot11s {
41
class
AirtimeLinkMetricCalculator
:
public
Object
42
{
43
public
:
44
AirtimeLinkMetricCalculator
();
49
static
TypeId
GetTypeId
();
66
uint32_t
CalculateMetric
(
Mac48Address
peerAddress,
Ptr<MeshWifiInterfaceMac>
mac
);
67
private
:
72
void
SetTestLength
(uint16_t testLength);
77
void
SetHeaderTid
(uint8_t tid);
78
79
Ptr<Packet>
m_testFrame
;
80
WifiMacHeader
m_testHeader
;
81
};
82
}
// namespace dot11s
83
}
// namespace ns3
84
#endif
ns3::Ptr
Smart pointer class similar to boost::intrusive_ptr.
Definition:
ptr.h:73
ns3::dot11s::AirtimeLinkMetricCalculator::SetHeaderTid
void SetHeaderTid(uint8_t tid)
Set header TID from the Dot11MetricTid attribute.
Definition:
airtime-metric.cc:56
ns3::dot11s::AirtimeLinkMetricCalculator::CalculateMetric
uint32_t CalculateMetric(Mac48Address peerAddress, Ptr< MeshWifiInterfaceMac > mac)
Airtime link metric is defined in Section 13.9 of IEEE 802.11-2012 as:
Definition:
airtime-metric.cc:69
ns3::dot11s::AirtimeLinkMetricCalculator::AirtimeLinkMetricCalculator
AirtimeLinkMetricCalculator()
Definition:
airtime-metric.cc:52
third.mac
mac
Definition:
third.py:92
ns3::dot11s::AirtimeLinkMetricCalculator
Airtime link metric calculator.
Definition:
airtime-metric.h:41
ns3::dot11s::AirtimeLinkMetricCalculator::GetTypeId
static TypeId GetTypeId()
Get the type ID.
Definition:
airtime-metric.cc:29
ns3::dot11s::AirtimeLinkMetricCalculator::SetTestLength
void SetTestLength(uint16_t testLength)
Set number of bytes in test frame (a constant 1024 in the standard)
Definition:
airtime-metric.cc:64
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::Mac48Address
an EUI-48 address
Definition:
mac48-address.h:43
ns3::dot11s::AirtimeLinkMetricCalculator::m_testFrame
Ptr< Packet > m_testFrame
test frame
Definition:
airtime-metric.h:79
ns3::Object
A base class which provides memory management and object aggregation.
Definition:
object.h:87
ns3::dot11s::AirtimeLinkMetricCalculator::m_testHeader
WifiMacHeader m_testHeader
test header
Definition:
airtime-metric.h:80
ns3::TypeId
a unique identifier for an interface.
Definition:
type-id.h:58
ns3::WifiMacHeader
Implements the IEEE 802.11 MAC header.
Definition:
wifi-mac-header.h:83
Generated on Wed Nov 7 2018 10:02:04 for ns-3 by
1.8.14