public abstract class Source extends Object
SpdyStream
.Modifier and Type | Class and Description |
---|---|
static class |
Source.SourceFactory
|
Constructor and Description |
---|
Source() |
Modifier and Type | Method and Description |
---|---|
static Source.SourceFactory |
factory(SpdyStream spdyStream)
Returns the
Source.SourceFactory associated with the SpdyStream . |
abstract boolean |
hasRemaining()
Returns true if there is more data to be written, or false
otherwise.
|
abstract Buffer |
read(int length)
Returns the number of bytes to be written.
|
abstract void |
release()
The method is called, when the source might be released/closed.
|
abstract long |
remaining()
Returns the number of bytes remaining to be written.
|
public abstract long remaining()
public abstract Buffer read(int length) throws SpdyStreamException
length
- max number of bytes to return.Buffer
, which contains up to length bytes
(could return less) to be written. null result is not
permitted.SpdyStreamException
public abstract boolean hasRemaining()
public abstract void release()
public static Source.SourceFactory factory(SpdyStream spdyStream)
Source.SourceFactory
associated with the SpdyStream
.Copyright © 2015 Oracle Corporation. All rights reserved.