A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
ht-configuration.cc
Go to the documentation of this file.
1/*
2 * Copyright (c) 2018 Sébastien Deronne
3 *
4 * SPDX-License-Identifier: GPL-2.0-only
5 *
6 * Author: Sébastien Deronne <sebastien.deronne@gmail.com>
7 */
8
9#include "ht-configuration.h"
10
11#include "ns3/boolean.h"
12#include "ns3/log.h"
13#include "ns3/uinteger.h"
14
15namespace ns3
16{
17
18NS_LOG_COMPONENT_DEFINE("HtConfiguration");
19
20NS_OBJECT_ENSURE_REGISTERED(HtConfiguration);
21
26
31
34{
35 static ns3::TypeId tid =
36 ns3::TypeId("ns3::HtConfiguration")
38 .SetGroupName("Wifi")
39 .AddConstructor<HtConfiguration>()
40 .AddAttribute("ShortGuardIntervalSupported",
41 "Whether or not short guard interval is supported.",
42 BooleanValue(false),
45 .AddAttribute("LdpcSupported",
46 "Whether or not LDPC coding is supported.",
47 BooleanValue(false),
50 // NS_DEPRECATED_3_45
51 .AddAttribute("Support40MHzOperation",
52 "Whether or not 40 MHz operation is to be supported.",
53 BooleanValue(true),
57 "Set an initial channel via WifiPhy::ChannelSettings whose width "
58 "corresponds to the maximum desired width instead");
59 return tid;
60}
61
62void
64{
65 NS_LOG_FUNCTION(this << enable);
66 m_sgiSupported = enable;
67}
68
69bool
74
75void
77{
78 NS_LOG_FUNCTION(this << enable);
79 m_ldpcSupported = enable;
80}
81
82bool
87
88void
90{
91 NS_LOG_FUNCTION(this << enable);
92 m_40MHzSupported = enable;
93}
94
95bool
100
101} // namespace ns3
AttributeValue implementation for Boolean.
Definition boolean.h:26
HT configuration.
bool m_40MHzSupported
whether 40 MHz operation is supported
bool Get40MHzOperationSupported() const
bool GetShortGuardIntervalSupported() const
bool m_ldpcSupported
flag whether LDPC coding is supported
void Set40MHzOperationSupported(bool enable)
Enable or disable 40 MHz operation support.
void SetShortGuardIntervalSupported(bool enable)
Enable or disable SGI support.
static TypeId GetTypeId()
Get the type ID.
bool m_sgiSupported
flag whether short guard interval is supported
void SetLdpcSupported(bool enable)
Enable or disable LDPC support.
bool GetLdpcSupported() const
A base class which provides memory management and object aggregation.
Definition object.h:78
a unique identifier for an interface.
Definition type-id.h:49
TypeId SetParent(TypeId tid)
Set the parent TypeId.
Definition type-id.cc:1001
@ OBSOLETE
Attribute or trace source is not used anymore; simulation fails.
Ptr< const AttributeChecker > MakeBooleanChecker()
Definition boolean.cc:113
Ptr< const AttributeAccessor > MakeBooleanAccessor(T1 a1)
Create an AttributeAccessor for a class data member, or a lone class get functor or set method.
Definition boolean.h:70
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
Definition log.h:191
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by ",...
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
Definition object-base.h:35
Every class exported by the ns3 library is enclosed in the ns3 namespace.