Code example for Supplier

Methods: get

0
    } 
 
    public T poll(Supplier<T> supplier) {
        T bb = super.poll();
        if (bb == null) {
            return supplier.get();
        } 
        return bb;
    } 
} 
Connect your IDE to all the code out there  Get Codota for Java