Queue

From CometPublic

Jump to: navigation, search

This is the class that supports queues of items and is declared with statements like

  queue{int} x();

With this declaration, x is an instance of the class queue that has the following API.

   class queue{T} {
      bool empty()
      enqueueFront(T)
      enqueueBack(T)
      T dequeueFront()
      T dequeueBack()
      T peekFront()
      T peekBack()
      int getSize()
      void reset()
   }