public abstract class Source extends Object
Http2Stream
.Modifier and Type | Class and Description |
---|---|
static class |
Source.SourceFactory
|
Constructor and Description |
---|
Source() |
Modifier and Type | Method and Description |
---|---|
static Source.SourceFactory |
factory(Http2Stream spdyStream)
Returns the
Source.SourceFactory associated with the Http2Stream . |
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 Http2StreamException
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.Http2StreamException
public abstract boolean hasRemaining()
public abstract void release()
public static Source.SourceFactory factory(Http2Stream spdyStream)
Source.SourceFactory
associated with the Http2Stream
.Copyright © 2018 Oracle Corporation. All rights reserved.