A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Documentation ▼
Installation
Manual
Models
Contributing
Wiki
Development ▼
API Docs
Issue Tracker
Merge Requests
API
ie-dot11s-metric-report.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2008,2009 IITP RAS
3
*
4
* This program is free software; you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License version 2 as
6
* published by the Free Software Foundation;
7
*
8
* This program is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
* GNU General Public License for more details.
12
*
13
* You should have received a copy of the GNU General Public License
14
* along with this program; if not, write to the Free Software
15
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16
*
17
* Author: Kirill Andreev <andreev@iitp.ru>
18
*/
19
20
#ifndef METRIC_REPORT_H
21
#define METRIC_REPORT_H
22
23
#include "ns3/buffer.h"
24
#include "ns3/mesh-information-element-vector.h"
25
26
#include <stdint.h>
27
28
namespace
ns3
29
{
30
namespace
dot11s
31
{
36
class
IeLinkMetricReport
:
public
WifiInformationElement
37
{
38
public
:
39
IeLinkMetricReport
();
45
IeLinkMetricReport
(uint32_t metric);
50
void
SetMetric
(uint32_t metric);
55
uint32_t
GetMetric
()
const
;
56
57
// Inherited from WifiInformationElement
58
WifiInformationElementId
ElementId
()
const override
;
59
void
SerializeInformationField
(
Buffer::Iterator
i)
const override
;
60
uint16_t
DeserializeInformationField
(
Buffer::Iterator
start
, uint16_t length)
override
;
61
void
Print
(std::ostream& os)
const override
;
62
uint16_t
GetInformationFieldSize
()
const override
;
63
64
private
:
65
uint32_t
m_metric
;
73
friend
bool
operator==
(
const
IeLinkMetricReport
& a,
const
IeLinkMetricReport
& b);
81
friend
bool
operator>
(
const
IeLinkMetricReport
& a,
const
IeLinkMetricReport
& b);
89
friend
bool
operator<
(
const
IeLinkMetricReport
& a,
const
IeLinkMetricReport
& b);
90
};
91
92
bool
operator==
(
const
IeLinkMetricReport
& a,
const
IeLinkMetricReport
& b);
93
bool
operator>
(
const
IeLinkMetricReport
& a,
const
IeLinkMetricReport
& b);
94
bool
operator<
(
const
IeLinkMetricReport
& a,
const
IeLinkMetricReport
& b);
95
std::ostream&
operator<<
(std::ostream& os,
const
IeLinkMetricReport
& linkMetricReport);
96
}
// namespace dot11s
97
}
// namespace ns3
98
#endif
/* METRIC_REPORT_H */
ns3::Buffer::Iterator
iterator in a Buffer instance
Definition:
buffer.h:100
ns3::WifiInformationElement
Information element, as defined in 802.11-2007 standard.
Definition:
wifi-information-element.h:287
ns3::dot11s::IeLinkMetricReport
a IEEE 802.11s Mesh ID 7.3.2.88 of 802.11s draft 3.0
Definition:
ie-dot11s-metric-report.h:37
ns3::dot11s::IeLinkMetricReport::operator<
friend bool operator<(const IeLinkMetricReport &a, const IeLinkMetricReport &b)
less than operator
Definition:
ie-dot11s-metric-report.cc:89
ns3::dot11s::IeLinkMetricReport::m_metric
uint32_t m_metric
metric
Definition:
ie-dot11s-metric-report.h:65
ns3::dot11s::IeLinkMetricReport::ElementId
WifiInformationElementId ElementId() const override
Get the wifi information element ID.
Definition:
ie-dot11s-metric-report.cc:39
ns3::dot11s::IeLinkMetricReport::Print
void Print(std::ostream &os) const override
Generate human-readable form of IE.
Definition:
ie-dot11s-metric-report.cc:77
ns3::dot11s::IeLinkMetricReport::operator==
friend bool operator==(const IeLinkMetricReport &a, const IeLinkMetricReport &b)
equality operator
Definition:
ie-dot11s-metric-report.cc:83
ns3::dot11s::IeLinkMetricReport::GetMetric
uint32_t GetMetric() const
Get metric value.
Definition:
ie-dot11s-metric-report.cc:51
ns3::dot11s::IeLinkMetricReport::GetInformationFieldSize
uint16_t GetInformationFieldSize() const override
Length of serialized information (i.e., the length of the body of the IE, not including the Element I...
Definition:
ie-dot11s-metric-report.cc:45
ns3::dot11s::IeLinkMetricReport::SetMetric
void SetMetric(uint32_t metric)
Set metric value.
Definition:
ie-dot11s-metric-report.cc:57
ns3::dot11s::IeLinkMetricReport::IeLinkMetricReport
IeLinkMetricReport()
Definition:
ie-dot11s-metric-report.cc:28
ns3::dot11s::IeLinkMetricReport::SerializeInformationField
void SerializeInformationField(Buffer::Iterator i) const override
Serialize information (i.e., the body of the IE, not including the Element ID and length octets)
Definition:
ie-dot11s-metric-report.cc:63
ns3::dot11s::IeLinkMetricReport::DeserializeInformationField
uint16_t DeserializeInformationField(Buffer::Iterator start, uint16_t length) override
Deserialize information (i.e., the body of the IE, not including the Element ID and length octets)
Definition:
ie-dot11s-metric-report.cc:69
ns3::dot11s::IeLinkMetricReport::operator>
friend bool operator>(const IeLinkMetricReport &a, const IeLinkMetricReport &b)
greater than operator
Definition:
ie-dot11s-metric-report.cc:95
ns3::dot11s::operator>
bool operator>(const IeLinkMetricReport &a, const IeLinkMetricReport &b)
Definition:
ie-dot11s-metric-report.cc:95
ns3::dot11s::operator<
bool operator<(const IeLinkMetricReport &a, const IeLinkMetricReport &b)
Definition:
ie-dot11s-metric-report.cc:89
ns3::dot11s::operator==
bool operator==(const MeshHeader &a, const MeshHeader &b)
Definition:
dot11s-mac-header.cc:198
ns3::dot11s::operator<<
std::ostream & operator<<(std::ostream &os, const IeBeaconTiming &a)
Definition:
ie-dot11s-beacon-timing.cc:242
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::WifiInformationElementId
uint8_t WifiInformationElementId
This type is used to represent an Information Element ID.
Definition:
wifi-information-element.h:45
two-ray-to-three-gpp-ch-calibration.start
start
Definition:
two-ray-to-three-gpp-ch-calibration.py:520
src
mesh
model
dot11s
ie-dot11s-metric-report.h
Generated on Sun Mar 3 2024 17:11:04 for ns-3 by
1.9.1