26 #include "ns3/packet.h"
27 #include "ns3/object.h"
28 #include "ns3/traced-callback.h"
29 #include "ns3/net-device.h"
30 #include "ns3/traced-value.h"
177 void EnableRunningAverage (
Time averageWindow);
178 void DisableRunningAverage (
void);
180 double GetQueueSizeAverage (
void);
181 double GetReceivedBytesPerSecondAverage (
void);
182 double GetReceivedPacketsPerSecondAverage (
void);
183 double GetDroppedBytesPerSecondAverage (
void);
184 double GetDroppedPacketsPerSecondAverage (
void);
186 double GetQueueSizeVariance (
void);
187 double GetReceivedBytesPerSecondVariance (
void);
188 double GetReceivedPacketsPerSecondVariance (
void);
189 double GetDroppedBytesPerSecondVariance (
void);
190 double GetDroppedPacketsPerSecondVariance (
void);
virtual bool DoEnqueue(Ptr< QueueItem > item)=0
Push an item in the queue.
QueueMode m_mode
queue mode (packets or bytes limited)
Simulation virtual time values and global simulation resolution.
Smart pointer class similar to boost::intrusive_ptr.
uint32_t m_nTotalDroppedBytes
Total dropped bytes.
void SetMaxBytes(uint32_t maxBytes)
Set the maximum amount of bytes that can be stored in this queue.
Use number of bytes for maximum queue size.
Forward calls to a chain of Callback.
uint32_t GetTotalDroppedPackets(void) const
TracedValue< uint32_t > m_nPackets
Number of packets in the queue.
uint32_t m_nTotalReceivedBytes
Total received bytes.
void ResetStatistics(void)
Resets the counts for dropped packets, dropped bytes, received packets, and received bytes...
uint32_t m_maxPackets
max packets in the queue
virtual Ptr< const QueueItem > DoPeek(void) const =0
Peek the front item in the queue.
TracedValue< uint32_t > m_nBytes
Number of bytes in the queue.
Abstract base class for packet Queues.
uint32_t GetTotalReceivedBytes(void) const
QueueMode
Enumeration of the modes supported in the class.
static TypeId GetTypeId(void)
Get the type ID.
uint32_t GetMaxPackets(void) const
uint32_t GetNPackets(void) const
uint32_t GetMaxBytes(void) const
Every class exported by the ns3 library is enclosed in the ns3 namespace.
TracedCallback< Ptr< const Packet > > m_traceDequeue
Traced callback: fired when a packet is dequeued.
Queue::QueueMode GetMode(void) const
Get the encapsulation mode of this device.
TracedCallback< Ptr< const Packet > > m_traceDrop
Traced callback: fired when a packet is dropped.
uint32_t m_maxBytes
max bytes in the queue
uint32_t GetNBytes(void) const
void Drop(Ptr< Packet > p)
Drop a packet.
void SetMode(Queue::QueueMode mode)
Set the operating mode of this device.
uint32_t GetTotalReceivedPackets(void) const
virtual Ptr< QueueItem > DoDequeue(void)=0
Pull an item from the queue.
uint32_t m_nTotalReceivedPackets
Total received packets.
void SetMaxPackets(uint32_t maxPackets)
Set the maximum amount of packets that can be stored in this queue.
uint32_t m_nTotalDroppedPackets
Total dropped packets.
void DequeueAll(void)
Flush the queue.
TracedCallback< Ptr< const Packet > > m_traceEnqueue
Traced callback: fired when a packet is enqueued.
Ptr< const QueueItem > Peek(void) const
Get a copy of the item at the front of the queue without removing it.
Use number of packets for maximum queue size.
uint32_t GetTotalDroppedBytes(void) const
A base class which provides memory management and object aggregation.
a unique identifier for an interface.
bool Enqueue(Ptr< QueueItem > item)
Place a queue item into the rear of the Queue.
Ptr< QueueItem > Dequeue(void)
Remove an item from the front of the Queue.