Guava ListenableFutureTask - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Guava ListenableFutureTask class.

This code example shows how to use the following methods:get
    @Override 
    public int read() throws IOException {
        if (currentBuffer == null || !currentBuffer.hasRemaining()) {
            if (m_taskIterator.hasNext()) {
                try { 
                    currentBuffer = m_taskIterator.next().get();
                } catch (Exception e) {
                    throw new IOException(e);
                } 
            } else { 
                return -1; 
            } 
        } 
        assert(currentBuffer.hasRemaining());
        return currentBuffer.get();
    } 
 
    @Override 
    public int read(byte b[], int off, int len) throws IOException {
        if (b == null) {
4
CodeRank