HttpData.@Deprecated public final class DefaultHttpData extends AbstractHttpData
HttpData implementation.EMPTY_DATA| Constructor and Description |
|---|
DefaultHttpData(byte[] data,
boolean endOfStream)
Deprecated.
Use the factory methods in
HttpData. |
| Modifier and Type | Method and Description |
|---|---|
byte[] |
array()
Deprecated.
Returns the underlying byte array of this data.
|
protected byte |
getByte(int index)
Deprecated.
Gets the
byte value at the given index. |
boolean |
isEndOfStream()
Deprecated.
Tells whether the stream should be ended when writing this object.
|
int |
length()
Deprecated.
Returns the length of this data.
|
String |
toString()
Deprecated.
|
DefaultHttpData |
withEndOfStream()
Deprecated.
Returns a new
HttpData whose HTTP/2 endOfStream flag is set. |
equals, hashCodeclone, finalize, getClass, notify, notifyAll, wait, wait, waitcopyOf, copyOf, copyOf, empty, isEmpty, of, of, of, of, of, of, ofAscii, ofAscii, ofAscii, offset, ofUtf8, ofUtf8, ofUtf8, toInputStream, toReader, toReaderAscii, toReaderUtf8, toString, toStringAscii, toStringUtf8, wrap, wrap, wrap@Deprecated public DefaultHttpData(byte[] data, boolean endOfStream)
HttpData.public byte[] array()
HttpDatapublic int length()
HttpDatapublic boolean isEndOfStream()
HttpObjectHttpHeaders-only responses or to more efficiently close the stream along with the last piece of
HttpData. This only has meaning for HttpObject writers, not readers.protected byte getByte(int index)
AbstractHttpDatabyte value at the given index.getByte in class AbstractHttpDatapublic DefaultHttpData withEndOfStream()
HttpDataHttpData whose HTTP/2 endOfStream flag is set.Copyright © 2020 LeanCloud. All rights reserved.