Kea 2.5.8
isc::dhcp::PacketQueueRing6 Class Reference

DHCPv6 packet queue buffer implementation. More...

#include <packet_queue_ring.h>

+ Inheritance diagram for isc::dhcp::PacketQueueRing6:

Public Member Functions

 PacketQueueRing6 (const std::string &queue_type, size_t capacity)
 Constructor.
 
virtual ~PacketQueueRing6 ()
 virtual Destructor
 
- Public Member Functions inherited from isc::dhcp::PacketQueueRing< Pkt6Ptr >
 PacketQueueRing (const std::string &queue_type, size_t capacity)
 Constructor.
 
virtual ~PacketQueueRing ()
 virtual Destructor
 
virtual void clear ()
 Discards all packets currently in the buffer.
 
virtual Pkt6Ptr dequeuePacket ()
 Dequeues the next packet from the queue.
 
virtual int eatPackets (const QueueEnd &)
 Discards packets from one end of the queue.
 
virtual bool empty () const
 Returns True if the queue is empty.
 
virtual void enqueuePacket (Pkt6Ptr packet, const SocketInfo &source)
 Adds a packet to the queue.
 
virtual size_t getCapacity () const
 Returns the maximum number of packets allowed in the buffer.
 
virtual data::ElementPtr getInfo () const
 Fetches pertinent information.
 
virtual size_t getSize () const
 Returns the current number of packets in the buffer.
 
virtual const Pkt6Ptr peek (const QueueEnd &from=QueueEnd::FRONT) const
 Gets the packet currently at one end of the queue.
 
virtual Pkt6Ptr popPacket (const QueueEnd &from=QueueEnd::FRONT)
 Pops a packet from the queue.
 
virtual void pushPacket (Pkt6Ptr &packet, const QueueEnd &to=QueueEnd::BACK)
 Pushes a packet onto the queue.
 
virtual void setCapacity (size_t capacity)
 Sets the maximum number of packets allowed in the buffer.
 
virtual bool shouldDropPacket (Pkt6Ptr, const SocketInfo &)
 Determines if a packet should be discarded.
 
- Public Member Functions inherited from isc::dhcp::PacketQueue< PacketTypePtr >
 PacketQueue (const std::string &queue_type)
 Constructor.
 
virtual ~PacketQueue ()
 Virtual destructor.
 
virtual void clear ()=0
 Discards all packets currently in the buffer.
 
virtual PacketTypePtr dequeuePacket ()=0
 Dequeues the next packet from the queue.
 
virtual bool empty () const =0
 return True if the queue is empty.
 
virtual void enqueuePacket (PacketTypePtr packet, const SocketInfo &source)=0
 Adds a packet to the queue.
 
virtual data::ElementPtr getInfo () const
 Fetches operational information about the current state of the queue.
 
std::string getInfoStr () const
 Fetches a JSON string representation of queue operational info.
 
std::string getQueueType ()
 
virtual size_t getSize () const =0
 Returns the current number of packets in the buffer.
 

Additional Inherited Members

- Static Public Attributes inherited from isc::dhcp::PacketQueueRing< Pkt6Ptr >
static const size_t MIN_RING_CAPACITY
 Minimum queue capacity permitted.
 

Detailed Description

DHCPv6 packet queue buffer implementation.

This implementation does not (currently) add any drop or packet skip logic, it operates as a verbatim ring queue for DHCPv6 packets.

Definition at line 246 of file packet_queue_ring.h.

Constructor & Destructor Documentation

◆ PacketQueueRing6()

isc::dhcp::PacketQueueRing6::PacketQueueRing6 ( const std::string &  queue_type,
size_t  capacity 
)
inline

Constructor.

Parameters
queue_typelogical name of the queue implementation
capacitymaximum number of packets the queue can hold

Definition at line 252 of file packet_queue_ring.h.

◆ ~PacketQueueRing6()

virtual isc::dhcp::PacketQueueRing6::~PacketQueueRing6 ( )
inlinevirtual

virtual Destructor

Definition at line 257 of file packet_queue_ring.h.


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