A Discrete-Event Network Simulator
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ns3::WifiInformationElementVector Class Reference

Information element vectorImplements a vector of WifiInformationElements. Information elements typically come in groups, and the WifiInformationElementVector class provides a representation of a series of IEs, and the facility for serialisation to and deserialisation from the over-the-air format. More...

#include <wifi-information-element-vector.h>

+ Inheritance diagram for ns3::WifiInformationElementVector:
+ Collaboration diagram for ns3::WifiInformationElementVector:

Public Types

typedef std::vector< Ptr
< WifiInformationElement >
>::iterator 
Iterator
 As soon as this is a vector, we define an Iterator. More...
 

Public Member Functions

 WifiInformationElementVector ()
 
 ~WifiInformationElementVector ()
 
bool AddInformationElement (Ptr< WifiInformationElement > element)
 add an IE, if maxSize has exceeded, returns false More...
 
Iterator Begin ()
 Returns Begin of the vector. More...
 
virtual uint32_t DeserializeSingleIe (Buffer::Iterator start)
 Needed when you try to deserialize a lonely IE inside other header. More...
 
Iterator End ()
 Returns End of the vector. More...
 
Ptr< WifiInformationElementFindFirst (WifiInformationElementId id) const
 vector of pointers to information elements is the body of IeVector More...
 
virtual bool operator== (const WifiInformationElementVector &a) const
 
void SetMaxSize (uint16_t size)
 Set maximum size to control overflow of the max packet length. More...
 
- Public Member Functions inherited from ns3::Header
virtual ~Header ()
 
- Public Member Functions inherited from ns3::ObjectBase
virtual ~ObjectBase ()
 
void GetAttribute (std::string name, AttributeValue &value) const
 
bool GetAttributeFailSafe (std::string name, AttributeValue &attribute) const
 
void SetAttribute (std::string name, const AttributeValue &value)
 
bool SetAttributeFailSafe (std::string name, const AttributeValue &value)
 
bool TraceConnect (std::string name, std::string context, const CallbackBase &cb)
 
bool TraceConnectWithoutContext (std::string name, const CallbackBase &cb)
 
bool TraceDisconnect (std::string name, std::string context, const CallbackBase &cb)
 
bool TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb)
 

Protected Types

typedef std::vector< Ptr
< WifiInformationElement > > 
IE_VECTOR
 

Protected Member Functions

uint32_t GetSize () const
 Current number of bytes. More...
 
- Protected Member Functions inherited from ns3::ObjectBase
void ConstructSelf (const AttributeConstructionList &attributes)
 
virtual void NotifyConstructionCompleted (void)
 

Protected Attributes

IE_VECTOR m_elements
 
uint16_t m_maxSize
 Size in bytes (actually, max packet length) More...
 

Inherited from Header

TypeId GetInstanceTypeId () const
 
virtual uint32_t GetSerializedSize () const
 
virtual void Serialize (Buffer::Iterator start) const
 
virtual uint32_t Deserialize (Buffer::Iterator start)
 
virtual void Print (std::ostream &os) const
 
static TypeId GetTypeId ()
 

Additional Inherited Members

- Static Public Member Functions inherited from ns3::Header
static TypeId GetTypeId (void)
 
- Static Public Member Functions inherited from ns3::Chunk
static TypeId GetTypeId (void)
 
- Static Public Member Functions inherited from ns3::ObjectBase
static TypeId GetTypeId (void)
 

Detailed Description

Information element vector

Implements a vector of WifiInformationElements. Information elements typically come in groups, and the WifiInformationElementVector class provides a representation of a series of IEs, and the facility for serialisation to and deserialisation from the over-the-air format.

Doxygen introspection did not find any typical Config paths.
No Attributes are defined for this type.
No TraceSources are defined for this type.

Definition at line 43 of file wifi-information-element-vector.h.

Member Typedef Documentation

As soon as this is a vector, we define an Iterator.

Definition at line 72 of file wifi-information-element-vector.h.

Constructor & Destructor Documentation

ns3::WifiInformationElementVector::WifiInformationElementVector ( )

Definition at line 29 of file wifi-information-element-vector.cc.

ns3::WifiInformationElementVector::~WifiInformationElementVector ( )

Definition at line 33 of file wifi-information-element-vector.cc.

References m_elements.

Member Function Documentation

bool ns3::WifiInformationElementVector::AddInformationElement ( Ptr< WifiInformationElement element)
WifiInformationElementVector::Iterator ns3::WifiInformationElementVector::Begin ( void  )

Returns Begin of the vector.

Definition at line 117 of file wifi-information-element-vector.cc.

References m_elements.

Referenced by ns3::dot11s::HwmpProtocolMac::ReceiveAction().

+ Here is the caller graph for this function:

uint32_t ns3::WifiInformationElementVector::Deserialize ( Buffer::Iterator  start)
virtual
Attention
When you use RemoveHeader, WifiInformationElementVector supposes, that all buffer consists of information elements
Parameters
start
Returns

Implements ns3::Header.

Definition at line 68 of file wifi-information-element-vector.cc.

References DeserializeSingleIe(), ns3::Buffer::Iterator::GetDistanceFrom(), ns3::Buffer::Iterator::GetSize(), ns3::Buffer::Iterator::Next(), and visualizer.core::start().

+ Here is the call graph for this function:

uint32_t ns3::WifiInformationElementVector::DeserializeSingleIe ( Buffer::Iterator  start)
virtual

Needed when you try to deserialize a lonely IE inside other header.

Parameters
startis the start of the buffer
Returns
deserialized bytes

Reimplemented in ns3::MeshInformationElementVector.

Definition at line 81 of file wifi-information-element-vector.cc.

References NS_FATAL_ERROR, ns3::Buffer::Iterator::ReadU8(), and visualizer.core::start().

Referenced by Deserialize(), and ns3::MeshInformationElementVector::DeserializeSingleIe().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

WifiInformationElementVector::Iterator ns3::WifiInformationElementVector::End ( void  )

Returns End of the vector.

Definition at line 122 of file wifi-information-element-vector.cc.

References m_elements.

Referenced by ns3::dot11s::HwmpProtocolMac::ReceiveAction().

+ Here is the caller graph for this function:

Ptr< WifiInformationElement > ns3::WifiInformationElementVector::FindFirst ( WifiInformationElementId  id) const

vector of pointers to information elements is the body of IeVector

Definition at line 137 of file wifi-information-element-vector.cc.

References m_elements.

Referenced by ns3::dot11s::PeerManagementProtocolMac::Receive().

+ Here is the caller graph for this function:

TypeId ns3::WifiInformationElementVector::GetInstanceTypeId ( void  ) const
virtual
Attention
When you use RemoveHeader, WifiInformationElementVector supposes, that all buffer consists of information elements
Parameters
start
Returns

Implements ns3::ObjectBase.

Definition at line 50 of file wifi-information-element-vector.cc.

References GetTypeId().

+ Here is the call graph for this function:

uint32_t ns3::WifiInformationElementVector::GetSerializedSize ( void  ) const
virtual
Attention
When you use RemoveHeader, WifiInformationElementVector supposes, that all buffer consists of information elements
Parameters
start
Returns

Implements ns3::Header.

Definition at line 55 of file wifi-information-element-vector.cc.

References GetSize().

+ Here is the call graph for this function:

uint32_t ns3::WifiInformationElementVector::GetSize ( void  ) const
protected

Current number of bytes.

Definition at line 159 of file wifi-information-element-vector.cc.

References m_elements.

Referenced by AddInformationElement(), ns3::MeshInformationElementVector::DeserializeSingleIe(), and GetSerializedSize().

+ Here is the caller graph for this function:

TypeId ns3::WifiInformationElementVector::GetTypeId ( void  )
static
Attention
When you use RemoveHeader, WifiInformationElementVector supposes, that all buffer consists of information elements
Parameters
start
Returns

Definition at line 42 of file wifi-information-element-vector.cc.

References ns3::TypeId::SetParent().

Referenced by GetInstanceTypeId().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool ns3::WifiInformationElementVector::operator== ( const WifiInformationElementVector a) const
virtual

Definition at line 170 of file wifi-information-element-vector.cc.

References m_elements, and NS_ASSERT.

void ns3::WifiInformationElementVector::Print ( std::ostream &  os) const
virtual
Parameters
osoutput stream This method is used by Packet::Print to print the content of a trailer as ascii data to a c++ output stream. Although the trailer 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
Todo:

Implements ns3::Header.

Definition at line 107 of file wifi-information-element-vector.cc.

void ns3::WifiInformationElementVector::Serialize ( Buffer::Iterator  start) const
virtual
Attention
When you use RemoveHeader, WifiInformationElementVector supposes, that all buffer consists of information elements
Parameters
start
Returns

Implements ns3::Header.

Definition at line 60 of file wifi-information-element-vector.cc.

References m_elements.

void ns3::WifiInformationElementVector::SetMaxSize ( uint16_t  size)

Set maximum size to control overflow of the max packet length.

Definition at line 112 of file wifi-information-element-vector.cc.

References m_maxSize.

Member Data Documentation

uint16_t ns3::WifiInformationElementVector::m_maxSize
protected

Size in bytes (actually, max packet length)

Definition at line 89 of file wifi-information-element-vector.h.

Referenced by AddInformationElement(), ns3::MeshInformationElementVector::DeserializeSingleIe(), and SetMaxSize().


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