Module logicng

Class LNGBoundedLongQueue


  • public final class LNGBoundedLongQueue
    extends Object
    A bounded long queue (for Glucose)
    Since:
    1.0
    Version:
    1.3
    • Constructor Detail

      • LNGBoundedLongQueue

        public LNGBoundedLongQueue()
        Constructs a new bounded long queue.
    • Method Detail

      • initSize

        public void initSize​(int size)
        Initializes the size of this queue.
        Parameters:
        size - the size
      • push

        public void push​(long x)
        Pushes a new element to the queue.
        Parameters:
        x - the new element
      • avg

        public int avg()
        Returns the average value of this queue.
        Returns:
        the average value of this queue
      • valid

        public boolean valid()
        Returns true if this queue is valid (the queue is filled completely) or false if it is not.
        Returns:
        true if this queue is valid
      • fastClear

        public void fastClear()
        Performs a fast clear of this queue (the elements are left untouched).