24 #include "ns3/uinteger.h"
35 .SetGroupName (
"Wifi")
37 .AddAttribute (
"AmpduExists",
"The value that indicates that the packet contains an AMPDU",
40 MakeUintegerChecker<uint8_t> ())
81 return (2 +
sizeof (
Time));
90 i.
Write ((
const uint8_t *)&duration,
sizeof(int64_t));
99 i.
Read ((uint8_t *)&duration, 8);
106 return (
m_ampdu == 1) ?
true :
false;
124 os <<
"A-MPDU exists=" <<
m_ampdu
126 <<
" Remaining A-MPDU duration=" <<
m_duration;
void Write(const uint8_t *buffer, uint32_t size)
Simulation virtual time values and global simulation resolution.
uint8_t GetRemainingNbOfMpdus(void) const
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
virtual void Print(std::ostream &os) const
#define NS_ASSERT(condition)
At runtime, in debugging builds, if this condition is not true, the program prints the source file...
Time MilliSeconds(uint64_t value)
Construct a Time in the indicated unit.
void(* Time)(Time oldValue, Time newValue)
TracedValue callback signature for Time.
bool GetAmpdu(void) const
TAG_BUFFER_INLINE uint8_t ReadU8(void)
virtual uint32_t GetSerializedSize() const
void SetAmpdu(bool supported)
Set m_ampdu to 1.
AmpduTag()
Create a AmpduTag with the default =0 no Ampdu.
Hold an unsigned integer type.
uint8_t m_nbOfMpdus
Remaining number of MPDUs in the A-MPDU.
The aim of the AmpduTag is to provide means for a MAC to specify that a packet includes A-MPDU since ...
tag a set of bytes in a packet
Every class exported by the ns3 library is enclosed in the ns3 namespace.
int64_t GetTimeStep(void) const
Get the raw time value, in the current resolution unit.
TAG_BUFFER_INLINE void WriteU8(uint8_t v)
virtual TypeId GetInstanceTypeId(void) const
Get the most derived TypeId for this Object.
virtual void Deserialize(TagBuffer i)
uint8_t m_ampdu
Flag whether it is an A-MPDU.
virtual void Serialize(TagBuffer i) const
Time Seconds(double value)
Construct a Time in the indicated unit.
void Read(uint8_t *buffer, uint32_t size)
static TypeId GetTypeId(void)
void SetRemainingNbOfMpdus(uint8_t nbofmpdus)
Ptr< const AttributeAccessor > MakeUintegerAccessor(T1 a1)
Create an AttributeAccessor for a class data member, or a lone class get functor or set method...
a unique identifier for an interface.
TypeId SetParent(TypeId tid)
Set the parent TypeId.
Time GetRemainingAmpduDuration(void) const
Time m_duration
Remaining duration of the A-MPDU in nanoseconds.
void SetRemainingAmpduDuration(Time duration)