|
A Discrete-Event Network Simulator
|
API
|
Go to the documentation of this file.
26 #include "ns3/attribute.h"
27 #include "ns3/attribute-helper.h"
28 #include "ns3/tag-buffer.h"
118 Address (uint8_t type,
const uint8_t *buffer, uint8_t len);
160 uint32_t
CopyAllTo (uint8_t *buffer, uint8_t len)
const;
171 uint32_t
CopyFrom (
const uint8_t *buffer, uint8_t len);
182 uint32_t
CopyAllFrom (
const uint8_t *buffer, uint8_t len);
void Deserialize(TagBuffer buffer)
bool CheckCompatible(uint8_t type, uint8_t len) const
Every class exported by the ns3 library is enclosed in the ns3 namespace.
uint8_t m_type
Type of the address.
bool operator<(const EventId &a, const EventId &b)
friend bool operator==(const Address &a, const Address &b)
Equal to operator.
static uint8_t Register(void)
Allocate a new type id for a new type of address.
friend bool operator<(const Address &a, const Address &b)
Less than operator.
friend std::istream & operator>>(std::istream &is, Address &address)
Stream extraction operator.
bool IsMatchingType(uint8_t type) const
uint8_t m_len
Length of the address.
Address()
Create an invalid address.
friend std::ostream & operator<<(std::ostream &os, const Address &address)
Stream insertion operator.
friend bool operator!=(const Address &a, const Address &b)
Not equal to operator.
uint8_t m_data[MAX_SIZE]
The address value.
Address & operator=(const Address &address)
Basic assignment operator.
a polymophic address class
MaxSize_e
The maximum size of a byte buffer which can be stored in an Address instance.
uint32_t CopyFrom(const uint8_t *buffer, uint8_t len)
bool operator==(const EventId &a, const EventId &b)
uint32_t CopyAllTo(uint8_t *buffer, uint8_t len) const
uint32_t CopyTo(uint8_t buffer[MAX_SIZE]) const
Copy the address bytes into a buffer.
bool IsInvalid(void) const
bool operator!=(Callback< R, T1, T2, T3, T4, T5, T6, T7, T8, T9 > a, Callback< R, T1, T2, T3, T4, T5, T6, T7, T8, T9 > b)
Inequality test.
uint8_t GetLength(void) const
Get the length of the underlying address.
uint32_t GetSerializedSize(void) const
Get the number of bytes needed to serialize the underlying Address Typically, this is GetLength () + ...
void Serialize(TagBuffer buffer) const
Serialize this address in host byte order to a byte buffer.
std::ostream & operator<<(std::ostream &os, const Angles &a)
uint32_t CopyAllFrom(const uint8_t *buffer, uint8_t len)
#define ATTRIBUTE_HELPER_HEADER(type)
Declare the attribute value, accessor and checkers for class type
std::istream & operator>>(std::istream &is, Angles &a)