public class ByteArrayContent
extends ByteArrayContent
Implementation of the class OutgoingContent.ByteArrayContent for sending array of bytes
class OutgoingContent.ByteArrayContentOutgoingContent.ByteArrayContent, OutgoingContent.NoContent, OutgoingContent.ProtocolUpgrade, OutgoingContent.ReadChannelContent, OutgoingContent.WriteChannelContent| Constructor and Description |
|---|
ByteArrayContent(byte[] bytes,
ContentType contentType,
HttpStatusCode status)
Implementation of the
class OutgoingContent.ByteArrayContent for sending array of bytes |
| Modifier and Type | Method and Description |
|---|---|
byte[] |
bytes()
Provides ByteArray which engine will send to peer
|
java.lang.Long |
getContentLength()
Specifies content length in bytes for this resource.
|
ContentType |
getContentType()
Specifies
|
HttpStatusCode |
getStatus()
Status code to set when sending this content
|
bytesgetContentLength, getContentType, getHeaders, getProperty, getStatus, setPropertypublic ByteArrayContent(byte[] bytes,
ContentType contentType,
HttpStatusCode status)
Implementation of the class OutgoingContent.ByteArrayContent for sending array of bytes
contentType - Specifies class ContentType for this resource.status - Status code to set when sending this contentclass OutgoingContent.ByteArrayContentpublic java.lang.Long getContentLength()
Specifies content length in bytes for this resource.
If null, the resources will be sent as Transfer-Encoding: chunked
public ContentType getContentType()
Specifies
class ContentType for this resource.
class ContentTypepublic HttpStatusCode getStatus()
Status code to set when sending this content