A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Documentation ▼
Installation
Manual
Models
Contributing
Wiki
Development ▼
API Docs
Issue Tracker
Merge Requests
API
Loading...
Searching...
No Matches
ampdu-tag.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2013
3
*
4
* SPDX-License-Identifier: GPL-2.0-only
5
*
6
* Authors: Ghada Badawy <gbadawy@gmail.com>
7
* Sébastien Deronne <sebastien.deronne@gmail.com>
8
*/
9
10
#ifndef AMPDU_TAG_H
11
#define AMPDU_TAG_H
12
13
#include "ns3/nstime.h"
14
#include "ns3/tag.h"
15
16
namespace
ns3
17
{
18
19
/**
20
* \ingroup wifi
21
*
22
* The aim of the AmpduTag is to provide means for a MAC to specify that a packet includes A-MPDU
23
* since this is done in HT-SIG and there is no HT-SIG representation in ns-3
24
*/
25
class
AmpduTag
:
public
Tag
26
{
27
public
:
28
/**
29
* \brief Get the type ID.
30
* \return the object TypeId
31
*/
32
static
TypeId
GetTypeId
();
33
34
TypeId
GetInstanceTypeId
()
const override
;
35
void
Serialize
(
TagBuffer
i)
const override
;
36
void
Deserialize
(
TagBuffer
i)
override
;
37
uint32_t
GetSerializedSize
()
const override
;
38
void
Print
(std::ostream& os)
const override
;
39
40
/**
41
* Create a AmpduTag with the default =0 no A-MPDU
42
*/
43
AmpduTag
();
44
/**
45
* \param nbOfMpdus the remaining number of MPDUs
46
*
47
* Set the remaining number of MPDUs in the A-MPDU.
48
*/
49
void
SetRemainingNbOfMpdus
(uint8_t nbOfMpdus);
50
/**
51
* \param duration the remaining duration of the A-MPDU
52
*
53
* Set the remaining duration of the A-MPDU.
54
*/
55
void
SetRemainingAmpduDuration
(
Time
duration);
56
57
/**
58
* \return the remaining number of MPDUs in an A-MPDU
59
*
60
* Returns the remaining number of MPDUs in an A-MPDU
61
*/
62
uint8_t
GetRemainingNbOfMpdus
()
const
;
63
/**
64
* \return the remaining duration of an A-MPDU
65
*
66
* Returns the remaining duration of an A-MPDU
67
*/
68
Time
GetRemainingAmpduDuration
()
const
;
69
70
private
:
71
uint8_t
m_nbOfMpdus
;
//!< Remaining number of MPDUs in the A-MPDU
72
Time
m_duration
;
//!< Remaining duration of the A-MPDU
73
};
74
75
}
// namespace ns3
76
77
#endif
/* AMPDU_TAG_H */
ns3::AmpduTag
The aim of the AmpduTag is to provide means for a MAC to specify that a packet includes A-MPDU since ...
Definition
ampdu-tag.h:26
ns3::AmpduTag::GetSerializedSize
uint32_t GetSerializedSize() const override
Definition
ampdu-tag.cc:51
ns3::AmpduTag::AmpduTag
AmpduTag()
Create a AmpduTag with the default =0 no A-MPDU.
Definition
ampdu-tag.cc:31
ns3::AmpduTag::SetRemainingNbOfMpdus
void SetRemainingNbOfMpdus(uint8_t nbOfMpdus)
Definition
ampdu-tag.cc:38
ns3::AmpduTag::m_duration
Time m_duration
Remaining duration of the A-MPDU.
Definition
ampdu-tag.h:72
ns3::AmpduTag::GetTypeId
static TypeId GetTypeId()
Get the type ID.
Definition
ampdu-tag.cc:18
ns3::AmpduTag::GetRemainingAmpduDuration
Time GetRemainingAmpduDuration() const
Definition
ampdu-tag.cc:80
ns3::AmpduTag::Deserialize
void Deserialize(TagBuffer i) override
Definition
ampdu-tag.cc:65
ns3::AmpduTag::SetRemainingAmpduDuration
void SetRemainingAmpduDuration(Time duration)
Definition
ampdu-tag.cc:44
ns3::AmpduTag::Serialize
void Serialize(TagBuffer i) const override
Definition
ampdu-tag.cc:57
ns3::AmpduTag::Print
void Print(std::ostream &os) const override
Definition
ampdu-tag.cc:86
ns3::AmpduTag::GetRemainingNbOfMpdus
uint8_t GetRemainingNbOfMpdus() const
Definition
ampdu-tag.cc:74
ns3::AmpduTag::m_nbOfMpdus
uint8_t m_nbOfMpdus
Remaining number of MPDUs in the A-MPDU.
Definition
ampdu-tag.h:71
ns3::AmpduTag::GetInstanceTypeId
TypeId GetInstanceTypeId() const override
Get the most derived TypeId for this Object.
Definition
ampdu-tag.cc:26
ns3::TagBuffer
read and write tag data
Definition
tag-buffer.h:41
ns3::Tag
tag a set of bytes in a packet
Definition
tag.h:28
ns3::Time
Simulation virtual time values and global simulation resolution.
Definition
nstime.h:94
ns3::TypeId
a unique identifier for an interface.
Definition
type-id.h:48
uint32_t
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
src
wifi
model
ampdu-tag.h
Generated on Fri Nov 8 2024 13:59:07 for ns-3 by
1.11.0