Go to the documentation of this file.
26 template<
class Thing,
int max_size>
34 INLINE
int size()
const;
38 INLINE
bool empty()
const;
40 INLINE
const Thing &
front()
const;
41 INLINE Thing &
front();
49 INLINE
bool full()
const;
51 INLINE
const Thing &
back()
const;
58 Thing _array[max_size+1];
void clear()
Removes all items from the queue.
const Thing & operator[](int n) const
Returns the nth element in the buffer.
const Thing & back() const
Returns a reference to the last item in the queue.
int size() const
Returns the number of items currently in the buffer.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
bool empty() const
Returns true if the buffer is empty.
void pop_front()
Removes the first item from the buffer.
bool full() const
Returns true if the buffer is full; if this is true, push_back() will fail.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
This class implements a queue of some type via a circular buffer.
const Thing & front() const
Returns a reference to the first item in the queue.
void push_back(const Thing &t)
Adds an item to the end of the buffer.