Implement the header for management frames of type association and reassociation response. More...
#include "mgt-headers.h"
Public Member Functions | |
~MgtAssocResponseHeader () override=default | |
CapabilityInformation & | Capabilities () |
const CapabilityInformation & | Capabilities () const |
uint16_t | GetAssociationId () const |
Return the association ID. | |
TypeId | GetInstanceTypeId () const override |
Get the most derived TypeId for this Object. | |
StatusCode | GetStatusCode () |
Return the status code. | |
void | SetAssociationId (uint16_t aid) |
Set the association ID. | |
void | SetStatusCode (StatusCode code) |
Set the status code. | |
Static Public Member Functions | |
static TypeId | GetTypeId () |
Register this type. | |
Protected Member Functions | |
uint32_t | DeserializeFromPerStaProfileImpl (Buffer::Iterator start, uint16_t length, const MgtAssocResponseHeader &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 MgtAssocResponseHeader &frame) const |
void | PrintImpl (std::ostream &os) const |
void | SerializeImpl (Buffer::Iterator start) const |
void | SerializeInPerStaProfileImpl (Buffer::Iterator start, const MgtAssocResponseHeader &frame) const |
Serialize this header into a Per-STA Profile subelement of a Multi-Link Element. | |
Private Attributes | |
uint16_t | m_aid {0} |
AID. | |
CapabilityInformation | m_capability |
Capability information. | |
StatusCode | m_code |
Status code. | |
Friends | |
class | MgtHeaderInPerStaProfile< MgtAssocResponseHeader, AssocResponseElems > |
class | WifiMgtHeader< MgtAssocResponseHeader, AssocResponseElems > |
Implement the header for management frames of type association and reassociation response.
Introspection did not find any typical Config paths.
No Attributes are defined for this type.
No TraceSources are defined for this type.
Size of this type is 1584 bytes (on a 64-bit architecture).
Definition at line 336 of file mgt-headers.h.
|
overridedefault |
CapabilityInformation & ns3::MgtAssocResponseHeader::Capabilities | ( | ) |
Definition at line 475 of file mgt-headers.cc.
References m_capability.
Referenced by ns3::ApWifiMac::GetAssocResp().
const CapabilityInformation & ns3::MgtAssocResponseHeader::Capabilities | ( | ) | const |
Definition at line 469 of file mgt-headers.cc.
References m_capability.
|
protected |
Deserialize this header from a Per-STA Profile subelement of a Multi-Link Element.
start | an iterator which points to where the header should be read from |
length | the expected number of bytes to read |
frame | the frame containing the Multi-Link Element |
Definition at line 574 of file mgt-headers.cc.
References ns3::CapabilityInformation::Deserialize(), ns3::StatusCode::Deserialize(), ns3::Buffer::Iterator::GetDistanceFrom(), m_aid, m_capability, m_code, and NS_ASSERT_MSG.
|
protected |
start | an iterator which points to where the header should read from. |
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 550 of file mgt-headers.cc.
References ns3::CapabilityInformation::Deserialize(), ns3::StatusCode::Deserialize(), ns3::Buffer::Iterator::GetDistanceFrom(), m_aid, m_capability, m_code, and ns3::Buffer::Iterator::ReadLsbtohU16().
uint16_t ns3::MgtAssocResponseHeader::GetAssociationId | ( | ) | const |
Return the association ID.
Definition at line 487 of file mgt-headers.cc.
References m_aid.
Referenced by ns3::StaWifiMac::ReceiveAssocResp().
|
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.
Definition at line 451 of file mgt-headers.cc.
References GetTypeId().
|
protected |
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 493 of file mgt-headers.cc.
References ns3::CapabilityInformation::GetSerializedSize(), ns3::StatusCode::GetSerializedSize(), m_capability, and m_code.
|
protected |
frame | the frame containing the Multi-Link Element |
Definition at line 506 of file mgt-headers.cc.
References ns3::CapabilityInformation::GetSerializedSize(), ns3::StatusCode::GetSerializedSize(), GetSerializedSizeInPerStaProfileImpl(), m_capability, and m_code.
Referenced by GetSerializedSizeInPerStaProfileImpl().
StatusCode ns3::MgtAssocResponseHeader::GetStatusCode | ( | ) |
Return the status code.
Definition at line 457 of file mgt-headers.cc.
References m_code.
Referenced by ns3::ApWifiMac::GetLinkIdStaAddrMap(), ns3::StaWifiMac::ReceiveAssocResp(), and ns3::ApWifiMac::SetAid().
|
static |
Register this type.
Definition at line 441 of file mgt-headers.cc.
References ns3::TypeId::SetParent().
Referenced by GetInstanceTypeId().
|
protected |
os | output stream This method is used by Packet::Print to print the content of a header as ascii data to a c++ output stream. Although the header is free to format its output as it wishes, it is recommended to follow a few rules to integrate with the packet pretty printer: start with flags, small field values located between a pair of parens. Values should be separated by whitespace. Follow the parens with the important fields, separated by whitespace. i.e.: (field1 val1 field2 val2 field3 val3) field4 val4 field5 val5 |
Definition at line 519 of file mgt-headers.cc.
|
protected |
start | an 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 527 of file mgt-headers.cc.
References m_aid, m_capability, m_code, ns3::CapabilityInformation::Serialize(), ns3::StatusCode::Serialize(), and ns3::Buffer::Iterator::WriteHtolsbU16().
|
protected |
Serialize this header into a Per-STA Profile subelement of a Multi-Link Element.
start | an iterator which points to where the header should be written |
frame | the frame containing the Multi-Link Element |
Definition at line 539 of file mgt-headers.cc.
References m_capability, m_code, ns3::CapabilityInformation::Serialize(), ns3::StatusCode::Serialize(), and SerializeInPerStaProfileImpl().
Referenced by SerializeInPerStaProfileImpl().
void ns3::MgtAssocResponseHeader::SetAssociationId | ( | uint16_t | aid | ) |
Set the association ID.
aid | the association ID |
Definition at line 481 of file mgt-headers.cc.
References m_aid.
Referenced by ns3::ApWifiMac::SetAid().
void ns3::MgtAssocResponseHeader::SetStatusCode | ( | StatusCode | code | ) |
Set the status code.
code | the status code |
Definition at line 463 of file mgt-headers.cc.
References m_code.
Referenced by ns3::ApWifiMac::GetAssocResp().
|
friend |
Definition at line 329 of file mgt-headers.h.
|
friend |
Definition at line 329 of file mgt-headers.h.
|
private |
AID.
Definition at line 428 of file mgt-headers.h.
Referenced by DeserializeFromPerStaProfileImpl(), DeserializeImpl(), GetAssociationId(), PrintImpl(), SerializeImpl(), and SetAssociationId().
|
private |
Capability information.
Definition at line 426 of file mgt-headers.h.
Referenced by Capabilities(), DeserializeFromPerStaProfileImpl(), DeserializeImpl(), GetSerializedSizeImpl(), GetSerializedSizeInPerStaProfileImpl(), SerializeImpl(), and SerializeInPerStaProfileImpl().
|
private |
Status code.
Definition at line 427 of file mgt-headers.h.
Referenced by DeserializeFromPerStaProfileImpl(), DeserializeImpl(), GetSerializedSizeImpl(), GetSerializedSizeInPerStaProfileImpl(), GetStatusCode(), PrintImpl(), SerializeImpl(), SerializeInPerStaProfileImpl(), and SetStatusCode().