Code example for Queue

Methods: addAll

0
        } 
        return instances.poll();
    } 
 
    private void repopulateInstances() { 
        instances.addAll(retrieveNewInstances());
    } 
 
    protected abstract List retrieveNewInstances();
 
    @Override 
    public Object createNewInstance() {
        return getNextInstance(); 
    } 
 
    @Override 
    public void terminate() { 
        super.terminate(); 
        this.purgeInstances();
    } 
Stop searching for code, let great code find you!  Add Codota to your java IDE