src/main/java/com/ve/cxe/commons/collection/FastFixedPump.java
/**
     * @return Empty when pump runs dry, else pumping volume quantity is pumped out
     * Returned Array is not a new Object, rather the valve with the last pumped volume is returned
     */
@return Empty when pump runs dry, else pumping volume quantity is pumped out
Returned Array is not a new Object, rather the valve with the last pumped volume is returned
@return Empty when pump runs dry else pumping volume quantity is pumped out Returned Array is not a new Object rather the valve with the last pumped volume is returned
public Object[] pump() {
        if (current == 0) {
            return EMPTY_CONTAINER;
        }
        int valveCounter = 0;
        while (current != 0 && valveCounter < pumpingVolume) {
            current--;
            valve[valveCounter] = values[current];
            valveCounter++;
            values[current] = null;
        }
        return valve;
    }
public Object [ ] pump ( ) { if ( current == 0 ) { return EMPTY_CONTAINER ; } int valveCounter = 0 ; while ( current != 0 && valveCounter < pumpingVolume ) { current -- ; valve [ valveCounter ] = values [ current ] ; valveCounter ++ ; values [ current ] = null ; } return valve ; }
@return Empty when pump runs dry, else pumping volume quantity is pumped out
 Returned Array is not a new Object, rather the valve with the last pumped volume is returned
@return Empty when pump runs dry else pumping volume quantity is pumped out Returned Array is not a new Object rather the valve with the last pumped volume is returned
//Pump is running dry, and returns empty (never null) //Pre-fill the valve until length is reached or till pumping volume is reached //Shrink the pointer //Swap the pointer item into the first slot (now pulled into valve) //Make current as empty (for freeing up)