|
A Discrete-Event Network Simulator
|
API
|
Go to the documentation of this file.
38 #include "ns3/ipv4-route.h"
39 #include "ns3/socket.h"
109 if (i->GetNextHopAddress () == nextHop)
125 if (i->GetNextHopAddress () == nextHop)
180 if (i->GetInsertedTimeStamp () +
m_maxDelay > now)
a unique identifier for an interface.
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
void SetMaxNetworkDelay(Time delay)
Set the maximum entry lifetime in the queue.
uint32_t m_maxSize
Maximum queue size.
static Time Now(void)
Return the current simulation virtual time.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
void SetInsertedTimeStamp(Time time)
Set inserted time stamp function.
Time m_maxDelay
Maximum entry lifetime.
Ipv4 addresses are stored in host order in this class.
void Cleanup(void)
Clean the queue by removing entries that exceeded lifetime.
void SetMaxNetworkSize(uint32_t maxSize)
Set the maximum queue size.
uint32_t GetMaxNetworkSize(void) const
Return the maximum queue size.
TypeId SetParent(TypeId tid)
Set the parent TypeId.
A base class which provides memory management and object aggregation.
static TypeId GetTypeId(void)
Get the type ID.
Simulation virtual time values and global simulation resolution.
bool FindPacketWithNexthop(Ipv4Address nextHop, DsrNetworkQueueEntry &entry)
Find the packet entry with a given next hop.
#define NS_LOG_LOGIC(msg)
Use NS_LOG to output a message of level LOG_LOGIC.
Time GetMaxNetworkDelay(void) const
Return the maximum entry lifetime for this queue.
uint32_t m_size
Current queue size.
std::vector< DsrNetworkQueueEntry > m_dsrNetworkQueue
Queue (vector) of entries.
bool Dequeue(DsrNetworkQueueEntry &entry)
Return first found (the earliest) entry for given destination.
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by ",...
void Flush(void)
Clear the queue.
bool Enqueue(DsrNetworkQueueEntry &entry)
Push entry in queue, if there is no entry with the same packet and destination address in queue.
Introspection did not find any typical Config paths.
uint32_t GetSize()
Number of entries.
bool Find(Ipv4Address nextHop)
Try to find an entry with a particular next hop, and return true if found.