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

Implement the FILS (Fast Initial Link Setup) action frame. More...

#include "mgt-action-headers.h"

+ Inheritance diagram for ns3::FilsDiscHeader:
+ Collaboration diagram for ns3::FilsDiscHeader:

Classes

struct  FdCapability
 FD Capability subfield of FILS Discovery Information field. More...
 
struct  FilsDiscFrameControl
 FILS Discovery Frame Control subfield of FILS Discovery Information field. More...
 

Public Member Functions

 FilsDiscHeader ()
 
uint32_t Deserialize (Buffer::Iterator start) override
 
uint32_t GetInformationFieldSize () const
 
TypeId GetInstanceTypeId () const override
 Get the most derived TypeId for this Object.
 
uint32_t GetSerializedSize () const override
 
uint32_t GetSizeNonOptSubfields () const
 
const std::string & GetSsid () const
 
void Print (std::ostream &os) const override
 
void Serialize (Buffer::Iterator start) const override
 
void SetLengthSubfield ()
 sets value of Length subfield
 
void SetSsid (const std::string &ssid)
 Set the SSID field.
 
- Public Member Functions inherited from ns3::Header
 ~Header () override
 
virtual uint32_t Deserialize (Buffer::Iterator start, Buffer::Iterator end)
 Deserialize the object from a buffer iterator.
 
- Public Member Functions inherited from ns3::ObjectBase
virtual ~ObjectBase ()
 Virtual destructor.
 
void GetAttribute (std::string name, AttributeValue &value, bool permissive=false) const
 Get the value of an attribute, raising fatal errors if unsuccessful.
 
bool GetAttributeFailSafe (std::string name, AttributeValue &value) const
 Get the value of an attribute without raising errors.
 
void SetAttribute (std::string name, const AttributeValue &value)
 Set a single attribute, raising fatal errors if unsuccessful.
 
bool SetAttributeFailSafe (std::string name, const AttributeValue &value)
 Set a single attribute without raising errors.
 
bool TraceConnect (std::string name, std::string context, const CallbackBase &cb)
 Connect a TraceSource to a Callback with a context.
 
bool TraceConnectWithoutContext (std::string name, const CallbackBase &cb)
 Connect a TraceSource to a Callback without a context.
 
bool TraceDisconnect (std::string name, std::string context, const CallbackBase &cb)
 Disconnect from a TraceSource a Callback previously connected with a context.
 
bool TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb)
 Disconnect from a TraceSource a Callback previously connected without a context.
 

Static Public Member Functions

static TypeId GetTypeId ()
 
- Static Public Member Functions inherited from ns3::Header
static TypeId GetTypeId ()
 Get the type ID.
 
- Static Public Member Functions inherited from ns3::Chunk
static TypeId GetTypeId ()
 Get the type ID.
 
- Static Public Member Functions inherited from ns3::ObjectBase
static TypeId GetTypeId ()
 Get the type ID.
 

Public Attributes

OptFieldWithPresenceInd< uint8_t > m_accessNetOpt
 Access Network Options.
 
OptFieldWithPresenceInd< uint8_t > m_apConfigSeqNum
 AP Configuration Sequence Number (AP-CSN)
 
uint16_t m_beaconInt {0}
 Beacon Interval in TU (1024 us)
 
OptFieldWithPresenceInd< uint8_t > m_chCntrFreqSeg1
 Channel Center Frequency Segment 1.
 
OptFieldWithPresenceInd< FdCapabilitym_fdCap
 FD Capability.
 
FilsDiscFrameControl m_frameCtl
 FILS Discovery Frame Control.
 
OptFieldWithPresenceInd< uint8_t > m_len
 Length.
 
std::optional< uint8_t > m_opClass
 Operating Class.
 
OptFieldWithPresenceInd< uint8_t > m_primaryCh
 Primary Channel.
 
std::optional< ReducedNeighborReportm_rnr
 Reduced Neighbor Report.
 
std::optional< Timm_tim
 Traffic Indication Map element.
 
uint64_t m_timeStamp {0}
 Timestamp.
 

Private Attributes

std::string m_ssid
 SSID.
 

Additional Inherited Members

- Protected Member Functions inherited from ns3::ObjectBase
void ConstructSelf (const AttributeConstructionList &attributes)
 Complete construction of ObjectBase; invoked by derived classes.
 
virtual void NotifyConstructionCompleted ()
 Notifier called once the ObjectBase is fully constructed.
 

Detailed Description

Implement the FILS (Fast Initial Link Setup) action frame.

Introspection did not find any typical Config paths.

See sec. 9.6.7.36 of IEEE 802.11-2020 and IEEE 802.11ax-2021.


No Attributes are defined for this type.
No TraceSources are defined for this type.
Group: Wifi

Size of this type is 296 bytes (on a 64-bit architecture).

Definition at line 702 of file mgt-action-headers.h.

Constructor & Destructor Documentation

◆ FilsDiscHeader()

ns3::FilsDiscHeader::FilsDiscHeader ( )

Definition at line 1477 of file mgt-action-headers.cc.

Member Function Documentation

◆ Deserialize()

uint32_t ns3::FilsDiscHeader::Deserialize ( Buffer::Iterator start)
overridevirtual
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.

Implements ns3::Header.

Definition at line 1626 of file mgt-action-headers.cc.

References ns3::FilsDiscHeader::FilsDiscFrameControl::Deserialize(), ns3::Buffer::Iterator::GetDistanceFrom(), m_accessNetOpt, ns3::FilsDiscHeader::FilsDiscFrameControl::m_anoPresenceInd, m_apConfigSeqNum, ns3::FilsDiscHeader::FilsDiscFrameControl::m_apCsnPresenceInd, m_beaconInt, ns3::FilsDiscHeader::FilsDiscFrameControl::m_capPresenceInd, m_chCntrFreqSeg1, ns3::FilsDiscHeader::FilsDiscFrameControl::m_chCntrFreqSeg1PresenceInd, m_fdCap, m_frameCtl, m_len, ns3::FilsDiscHeader::FilsDiscFrameControl::m_lenPresenceInd, m_opClass, m_primaryCh, ns3::FilsDiscHeader::FilsDiscFrameControl::m_primChPresenceInd, m_rnr, m_ssid, ns3::FilsDiscHeader::FilsDiscFrameControl::m_ssidLen, m_tim, m_timeStamp, ns3::Buffer::Iterator::Next(), ns3::Buffer::Iterator::Read(), ns3::Buffer::Iterator::ReadLsbtohU16(), ns3::Buffer::Iterator::ReadLsbtohU64(), and ns3::Buffer::Iterator::ReadU8().

+ Here is the call graph for this function:

◆ GetInformationFieldSize()

uint32_t ns3::FilsDiscHeader::GetInformationFieldSize ( ) const
Returns
size of FILS Discovery Information field in octets

Definition at line 1501 of file mgt-action-headers.cc.

References GetSizeNonOptSubfields(), ns3::OptFieldWithPresenceInd< T >::has_value(), m_accessNetOpt, m_apConfigSeqNum, m_chCntrFreqSeg1, m_fdCap, m_len, m_opClass, and m_primaryCh.

Referenced by GetSerializedSize(), and SetLengthSubfield().

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

◆ GetInstanceTypeId()

TypeId ns3::FilsDiscHeader::GetInstanceTypeId ( ) const
overridevirtual

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.

Implements ns3::ObjectBase.

Definition at line 1472 of file mgt-action-headers.cc.

References GetTypeId().

+ Here is the call graph for this function:

◆ GetSerializedSize()

uint32_t ns3::FilsDiscHeader::GetSerializedSize ( ) const
overridevirtual
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.

Implements ns3::Header.

Definition at line 1515 of file mgt-action-headers.cc.

References GetInformationFieldSize(), m_rnr, and m_tim.

+ Here is the call graph for this function:

◆ GetSizeNonOptSubfields()

uint32_t ns3::FilsDiscHeader::GetSizeNonOptSubfields ( ) const
Returns
size of non-optional subfields in octets

Definition at line 1525 of file mgt-action-headers.cc.

References m_ssid.

Referenced by GetInformationFieldSize(), and SetLengthSubfield().

+ Here is the caller graph for this function:

◆ GetSsid()

const std::string & ns3::FilsDiscHeader::GetSsid ( ) const
Returns
the SSID

Definition at line 1495 of file mgt-action-headers.cc.

References m_ssid.

Referenced by WifiFilsFrameTest::ValidateFilsDiscFrame().

+ Here is the caller graph for this function:

◆ GetTypeId()

TypeId ns3::FilsDiscHeader::GetTypeId ( )
static
Returns
the object TypeId

Definition at line 1462 of file mgt-action-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:

◆ Print()

void ns3::FilsDiscHeader::Print ( std::ostream & os) const
overridevirtual
Parameters
osoutput 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

Implements ns3::Header.

Definition at line 1544 of file mgt-action-headers.cc.

References ns3::OptFieldWithPresenceInd< T >::has_value(), m_accessNetOpt, m_apConfigSeqNum, m_beaconInt, m_chCntrFreqSeg1, m_fdCap, m_frameCtl, m_len, m_opClass, m_primaryCh, m_ssid, m_tim, and m_timeStamp.

+ Here is the call graph for this function:

◆ Serialize()

void ns3::FilsDiscHeader::Serialize ( Buffer::Iterator start) const
overridevirtual
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.

Implements ns3::Header.

Definition at line 1585 of file mgt-action-headers.cc.

References ns3::OptFieldWithPresenceInd< T >::has_value(), m_accessNetOpt, m_apConfigSeqNum, m_beaconInt, m_chCntrFreqSeg1, m_fdCap, m_frameCtl, m_len, m_opClass, m_primaryCh, m_rnr, m_ssid, m_tim, ns3::Simulator::Now(), NS_ASSERT, ns3::FilsDiscHeader::FilsDiscFrameControl::Serialize(), ns3::Buffer::Iterator::Write(), ns3::Buffer::Iterator::WriteHtolsbU16(), ns3::Buffer::Iterator::WriteHtolsbU64(), and ns3::Buffer::Iterator::WriteU8().

+ Here is the call graph for this function:

◆ SetLengthSubfield()

void ns3::FilsDiscHeader::SetLengthSubfield ( )

sets value of Length subfield

Definition at line 1534 of file mgt-action-headers.cc.

References GetInformationFieldSize(), GetSizeNonOptSubfields(), m_len, NS_ABORT_MSG_IF, and ns3::OptFieldWithPresenceInd< T >::reset().

Referenced by ns3::ApWifiMac::GetFilsDiscovery().

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

◆ SetSsid()

void ns3::FilsDiscHeader::SetSsid ( const std::string & ssid)

Set the SSID field.

Parameters
ssidthe SSID

Definition at line 1488 of file mgt-action-headers.cc.

References m_frameCtl, m_ssid, and ns3::FilsDiscHeader::FilsDiscFrameControl::m_ssidLen.

Referenced by ns3::ApWifiMac::GetFilsDiscovery().

+ Here is the caller graph for this function:

Member Data Documentation

◆ m_accessNetOpt

OptFieldWithPresenceInd<uint8_t> ns3::FilsDiscHeader::m_accessNetOpt

Access Network Options.

Definition at line 837 of file mgt-action-headers.h.

Referenced by Deserialize(), GetInformationFieldSize(), Print(), and Serialize().

◆ m_apConfigSeqNum

OptFieldWithPresenceInd<uint8_t> ns3::FilsDiscHeader::m_apConfigSeqNum

AP Configuration Sequence Number (AP-CSN)

Definition at line 836 of file mgt-action-headers.h.

Referenced by Deserialize(), GetInformationFieldSize(), Print(), and Serialize().

◆ m_beaconInt

uint16_t ns3::FilsDiscHeader::m_beaconInt {0}

Beacon Interval in TU (1024 us)

Definition at line 830 of file mgt-action-headers.h.

Referenced by Deserialize(), ns3::ApWifiMac::GetFilsDiscovery(), Print(), and Serialize().

◆ m_chCntrFreqSeg1

OptFieldWithPresenceInd<uint8_t> ns3::FilsDiscHeader::m_chCntrFreqSeg1

Channel Center Frequency Segment 1.

Definition at line 838 of file mgt-action-headers.h.

Referenced by Deserialize(), GetInformationFieldSize(), Print(), and Serialize().

◆ m_fdCap

◆ m_frameCtl

FilsDiscFrameControl ns3::FilsDiscHeader::m_frameCtl

FILS Discovery Frame Control.

Definition at line 828 of file mgt-action-headers.h.

Referenced by Deserialize(), Print(), Serialize(), and SetSsid().

◆ m_len

OptFieldWithPresenceInd<uint8_t> ns3::FilsDiscHeader::m_len

◆ m_opClass

std::optional<uint8_t> ns3::FilsDiscHeader::m_opClass

Operating Class.

Definition at line 833 of file mgt-action-headers.h.

Referenced by Deserialize(), GetInformationFieldSize(), Print(), and Serialize().

◆ m_primaryCh

OptFieldWithPresenceInd<uint8_t> ns3::FilsDiscHeader::m_primaryCh

Primary Channel.

Definition at line 834 of file mgt-action-headers.h.

Referenced by Deserialize(), GetInformationFieldSize(), Print(), and Serialize().

◆ m_rnr

std::optional<ReducedNeighborReport> ns3::FilsDiscHeader::m_rnr

Reduced Neighbor Report.

Definition at line 841 of file mgt-action-headers.h.

Referenced by Deserialize(), ns3::ApWifiMac::GetFilsDiscovery(), GetSerializedSize(), and Serialize().

◆ m_ssid

std::string ns3::FilsDiscHeader::m_ssid
private

SSID.

Definition at line 845 of file mgt-action-headers.h.

Referenced by Deserialize(), GetSizeNonOptSubfields(), GetSsid(), Print(), Serialize(), and SetSsid().

◆ m_tim

std::optional<Tim> ns3::FilsDiscHeader::m_tim

Traffic Indication Map element.

Definition at line 842 of file mgt-action-headers.h.

Referenced by Deserialize(), GetSerializedSize(), Print(), and Serialize().

◆ m_timeStamp

uint64_t ns3::FilsDiscHeader::m_timeStamp {0}

Timestamp.

Definition at line 829 of file mgt-action-headers.h.

Referenced by Deserialize(), and Print().


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