code: public E poll() {
      E result = buffer.poll();
      if (producer != null) {
        producer.wakeUp();
      }
  
      return result;
    }
docs: Check if there is any item in the queue
  
  @return null if there is no item inside the queue