ns-3
|
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>
Public Types | |
typedef std::vector< Ptr < WifiInformationElement > >::iterator | Iterator |
As soon as this is a vector, we define an Iterator. |
Public Member Functions | |
virtual uint32_t | DeserializeSingleIe (Buffer::Iterator start) |
Needed when you try to deserialize a lonely IE inside other header. | |
void | SetMaxSize (uint16_t size) |
Set maximum size to control overflow of the max packet length. | |
Iterator | Begin () |
Returns Begin of the vector. | |
Iterator | End () |
Returns End of the vector. | |
bool | AddInformationElement (Ptr< WifiInformationElement > element) |
add an IE, if maxSize has exceeded, returns false | |
Ptr< WifiInformationElement > | FindFirst (WifiInformationElementId id) const |
vector of pointers to information elements is the body of IeVector | |
virtual bool | operator== (const WifiInformationElementVector &a) const |
Protected Types | |
typedef std::vector< Ptr < WifiInformationElement > > | IE_VECTOR |
Protected Member Functions | |
uint32_t | GetSize () const |
Current number of bytes. |
Protected Attributes | |
IE_VECTOR | m_elements |
uint16_t | m_maxSize |
Size in bytes (actually, max packet length) |
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 () |
This method returns the TypeId associated to ns3::WifiInformationElementVector. |
Additional Inherited Members |
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.
|
virtual |
start |
Implements ns3::Header.
References DeserializeSingleIe(), ns3::Buffer::Iterator::GetDistanceFrom(), ns3::Buffer::Iterator::GetSize(), and ns3::Buffer::Iterator::Next().
|
virtual |
Needed when you try to deserialize a lonely IE inside other header.
start | is the start of the buffer |
Reimplemented in ns3::MeshInformationElementVector.
References ns3::Buffer::Iterator::GetDistanceFrom(), GetSize(), m_maxSize, ns3::Buffer::Iterator::Next(), NS_FATAL_ERROR, and ns3::Buffer::Iterator::ReadU8().
Referenced by Deserialize().
|
virtual |
This method is typically implemented by ns3::Object::GetInstanceTypeId but some classes which derive from ns3::ObjectBase directly have to implement it themselves.
Implements ns3::ObjectBase.
References GetTypeId().
|
virtual |
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.
References GetSize().
|
static |
This method returns the TypeId associated to ns3::WifiInformationElementVector.
No Attributes defined for this type.
No TraceSources defined for this type.
Reimplemented from ns3::Header.
References ns3::TypeId::SetParent().
Referenced by GetInstanceTypeId().
|
virtual |
os | output 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 |
Implements ns3::Header.
|
virtual |
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.
Implements ns3::Header.