A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
ns3::MgtProbeResponseHeader Class Reference

Implement the header for management frames of type probe response. More...

#include "mgt-headers.h"

+ Inheritance diagram for ns3::MgtProbeResponseHeader:
+ Collaboration diagram for ns3::MgtProbeResponseHeader:

Public Member Functions

 ~MgtProbeResponseHeader () override=default
 
CapabilityInformationCapabilities ()
 
const CapabilityInformationCapabilities () const
 
uint64_t GetBeaconIntervalUs () const
 Return the beacon interval in microseconds unit.
 
TypeId GetInstanceTypeId () const override
 Get the most derived TypeId for this Object.
 
uint64_t GetTimestamp () const
 Return the time stamp.
 
void SetBeaconIntervalUs (uint64_t us)
 Set the beacon interval in microseconds unit.
 

Static Public Member Functions

static TypeId GetTypeId ()
 Register this type.
 

Protected Member Functions

uint32_t DeserializeFromPerStaProfileImpl (Buffer::Iterator start, uint16_t length, const MgtProbeResponseHeader &frame)
 Deserialize this header from a Per-STA Profile subelement of a Multi-Link Element.
 
uint32_t DeserializeImpl (Buffer::Iterator start)
 
uint32_t GetSerializedSizeImpl () const
 
uint32_t GetSerializedSizeInPerStaProfileImpl (const MgtProbeResponseHeader &frame) const
 
void SerializeImpl (Buffer::Iterator start) const
 
void SerializeInPerStaProfileImpl (Buffer::Iterator start, const MgtProbeResponseHeader &frame) const
 Serialize this header into a Per-STA Profile subelement of a Multi-Link Element.
 

Private Attributes

uint64_t m_beaconInterval
 Beacon interval.
 
CapabilityInformation m_capability
 Capability information.
 
uint64_t m_timestamp
 Timestamp.
 

Friends

class MgtHeaderInPerStaProfile< MgtProbeResponseHeader, ProbeResponseElems >
 
class WifiMgtHeader< MgtProbeResponseHeader, ProbeResponseElems >
 

Detailed Description

Implement the header for management frames of type probe response.

Definition at line 446 of file mgt-headers.h.

Constructor & Destructor Documentation

◆ ~MgtProbeResponseHeader()

ns3::MgtProbeResponseHeader::~MgtProbeResponseHeader ( )
overridedefault

Member Function Documentation

◆ Capabilities() [1/2]

CapabilityInformation & ns3::MgtProbeResponseHeader::Capabilities ( )
Returns
a reference to the Capability information

Definition at line 82 of file mgt-headers.cc.

References m_capability.

Referenced by ns3::ApWifiMac::GetProbeRespProfile(), ns3::StaWifiMac::ReceiveBeacon(), and ns3::ApWifiMac::SendOneBeacon().

+ Here is the caller graph for this function:

◆ Capabilities() [2/2]

const CapabilityInformation & ns3::MgtProbeResponseHeader::Capabilities ( ) const
Returns
a const reference to the Capability information

Definition at line 76 of file mgt-headers.cc.

References m_capability.

◆ DeserializeFromPerStaProfileImpl()

uint32_t ns3::MgtProbeResponseHeader::DeserializeFromPerStaProfileImpl ( Buffer::Iterator start,
uint16_t length,
const MgtProbeResponseHeader & frame )
protected

Deserialize this header from a Per-STA Profile subelement of a Multi-Link Element.

Parameters
startan iterator which points to where the header should be read from
lengththe expected number of bytes to read
framethe frame containing the Multi-Link Element
Returns
the number of bytes read

Definition at line 313 of file mgt-headers.cc.

References ns3::CapabilityInformation::Deserialize(), GetBeaconIntervalUs(), ns3::Buffer::Iterator::GetDistanceFrom(), GetTimestamp(), m_beaconInterval, m_capability, m_timestamp, and NS_ASSERT_MSG.

+ Here is the call graph for this function:

◆ DeserializeImpl()

uint32_t ns3::MgtProbeResponseHeader::DeserializeImpl ( Buffer::Iterator start)
protected

Parameters
startan iterator which points to where the header should read from.
Returns
the number of bytes read.

This method is used by Packet::RemoveHeader to re-create a header from the byte buffer of a packet. The data read is expected to match bit-for-bit the representation of this header in real networks.

Note that data is not actually removed from the buffer to which the iterator points. Both Packet::RemoveHeader() and Packet::PeekHeader() call Deserialize(), but only the RemoveHeader() has additional statements to remove the header bytes from the underlying buffer and associated metadata.

Definition at line 117 of file mgt-headers.cc.

References ns3::CapabilityInformation::Deserialize(), ns3::Buffer::Iterator::GetDistanceFrom(), m_beaconInterval, m_capability, m_timestamp, ns3::Buffer::Iterator::ReadLsbtohU16(), and ns3::Buffer::Iterator::ReadLsbtohU64().

+ Here is the call graph for this function:

◆ GetBeaconIntervalUs()

uint64_t ns3::MgtProbeResponseHeader::GetBeaconIntervalUs ( ) const

Return the beacon interval in microseconds unit.

Returns
beacon interval in microseconds unit

Definition at line 64 of file mgt-headers.cc.

References m_beaconInterval.

Referenced by DeserializeFromPerStaProfileImpl(), ns3::MeshWifiBeacon::GetBeaconInterval(), and ns3::dot11s::PeerManagementProtocolMac::Receive().

+ Here is the caller graph for this function:

◆ GetInstanceTypeId()

TypeId ns3::MgtProbeResponseHeader::GetInstanceTypeId ( ) const
override

Get the most derived TypeId for this Object.

This method is typically implemented by ns3::Object::GetInstanceTypeId but some classes which derive from ns3::ObjectBase directly have to implement it themselves.

Returns
The TypeId associated to the most-derived type of this instance.

Definition at line 58 of file mgt-headers.cc.

References GetTypeId().

+ Here is the call graph for this function:

◆ GetSerializedSizeImpl()

uint32_t ns3::MgtProbeResponseHeader::GetSerializedSizeImpl ( ) const
protected

Returns
the expected size of the header.

This method is used by Packet::AddHeader to store a header into the byte buffer of a packet. This method should return the number of bytes which are needed to store the full header data by Serialize.

Definition at line 94 of file mgt-headers.cc.

References ns3::CapabilityInformation::GetSerializedSize(), and m_capability.

+ Here is the call graph for this function:

◆ GetSerializedSizeInPerStaProfileImpl()

uint32_t ns3::MgtProbeResponseHeader::GetSerializedSizeInPerStaProfileImpl ( const MgtProbeResponseHeader & frame) const
protected
Parameters
framethe frame containing the Multi-Link Element
Returns
the number of bytes that are needed to serialize this header into a Per-STA Profile subelement of the Multi-Link Element

Definition at line 291 of file mgt-headers.cc.

References ns3::CapabilityInformation::GetSerializedSize(), GetSerializedSizeInPerStaProfileImpl(), and m_capability.

Referenced by GetSerializedSizeInPerStaProfileImpl().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetTimestamp()

uint64_t ns3::MgtProbeResponseHeader::GetTimestamp ( ) const

Return the time stamp.

Returns
time stamp

Definition at line 88 of file mgt-headers.cc.

References m_timestamp.

Referenced by DeserializeFromPerStaProfileImpl().

+ Here is the caller graph for this function:

◆ GetTypeId()

TypeId ns3::MgtProbeResponseHeader::GetTypeId ( )
static

Register this type.

Returns
The TypeId.

Definition at line 48 of file mgt-headers.cc.

References ns3::TypeId::SetParent().

Referenced by GetInstanceTypeId().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SerializeImpl()

void ns3::MgtProbeResponseHeader::SerializeImpl ( Buffer::Iterator start) const
protected

Parameters
startan iterator which points to where the header should be written.

This method is used by Packet::AddHeader to store a header into the byte buffer of a packet. The data written is expected to match bit-for-bit the representation of this header in a real network.

Definition at line 105 of file mgt-headers.cc.

References m_beaconInterval, m_capability, ns3::Simulator::Now(), ns3::CapabilityInformation::Serialize(), ns3::Buffer::Iterator::WriteHtolsbU16(), and ns3::Buffer::Iterator::WriteHtolsbU64().

+ Here is the call graph for this function:

◆ SerializeInPerStaProfileImpl()

void ns3::MgtProbeResponseHeader::SerializeInPerStaProfileImpl ( Buffer::Iterator start,
const MgtProbeResponseHeader & frame ) const
protected

Serialize this header into a Per-STA Profile subelement of a Multi-Link Element.

Parameters
startan iterator which points to where the header should be written
framethe frame containing the Multi-Link Element

Definition at line 303 of file mgt-headers.cc.

References m_capability, ns3::CapabilityInformation::Serialize(), and SerializeInPerStaProfileImpl().

Referenced by SerializeInPerStaProfileImpl().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SetBeaconIntervalUs()

void ns3::MgtProbeResponseHeader::SetBeaconIntervalUs ( uint64_t us)

Set the beacon interval in microseconds unit.

Parameters
usbeacon interval in microseconds unit

Definition at line 70 of file mgt-headers.cc.

References m_beaconInterval.

Referenced by ns3::MeshWifiBeacon::MeshWifiBeacon(), ns3::ApWifiMac::GetProbeRespProfile(), and ns3::ApWifiMac::SendOneBeacon().

+ Here is the caller graph for this function:

Friends And Related Symbol Documentation

◆ MgtHeaderInPerStaProfile< MgtProbeResponseHeader, ProbeResponseElems >

Definition at line 439 of file mgt-headers.h.

◆ WifiMgtHeader< MgtProbeResponseHeader, ProbeResponseElems >

Definition at line 439 of file mgt-headers.h.

Member Data Documentation

◆ m_beaconInterval

uint64_t ns3::MgtProbeResponseHeader::m_beaconInterval
private

◆ m_capability

◆ m_timestamp

uint64_t ns3::MgtProbeResponseHeader::m_timestamp
private

Timestamp.

Definition at line 528 of file mgt-headers.h.

Referenced by DeserializeFromPerStaProfileImpl(), DeserializeImpl(), and GetTimestamp().


The documentation for this class was generated from the following files: