Package io.vertx.httpproxy
Interface Body
-
public interface Body
Handles the HTTP proxy body.- Author:
- Julien Viet
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description static Body
body(Buffer buffer)
Create a newBody
instance.static Body
body(ReadStream<Buffer> stream)
Create a newBody
instance.static Body
body(ReadStream<Buffer> stream, long len)
Create a newBody
instance.long
length()
Get length of theBody
.ReadStream<Buffer>
stream()
Get stream of theBody
.
-
-
-
Method Detail
-
body
static Body body(ReadStream<Buffer> stream, long len)
Create a newBody
instance.- Parameters:
stream
- theReadStream
of the bodylen
- the determined length of the body- Returns:
- a reference to this, so the API can be used fluently
-
body
static Body body(ReadStream<Buffer> stream)
Create a newBody
instance.- Parameters:
stream
- theReadStream
of the body- Returns:
- a reference to this, so the API can be used fluently
-
body
static Body body(Buffer buffer)
Create a newBody
instance.- Parameters:
buffer
- theBuffer
of the body- Returns:
- a reference to this, so the API can be used fluently
-
length
long length()
Get length of theBody
.- Returns:
- the body length or
-1
if that can't be determined
-
stream
ReadStream<Buffer> stream()
Get stream of theBody
.- Returns:
- the body stream
-
-