Package org.takes.rs
Class RsFluent
- java.lang.Object
-
- org.takes.rs.RsWrap
-
- org.takes.rs.RsFluent
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RsFluent
withBody(byte[] body)
With this body.RsFluent
withBody(InputStream body)
With this body.RsFluent
withBody(CharSequence body)
With this body.RsFluent
withHeader(CharSequence header)
With this header.RsFluent
withHeader(CharSequence key, CharSequence value)
With this header.RsFluent
withStatus(int code)
With this status code.RsFluent
withType(CharSequence ctype)
With this content type.
-
-
-
Constructor Detail
-
RsFluent
public RsFluent()
Ctor.
-
RsFluent
public RsFluent(Response res)
Ctor.- Parameters:
res
- Original response
-
-
Method Detail
-
withStatus
public RsFluent withStatus(int code)
With this status code.- Parameters:
code
- Status code- Returns:
- New fluent response
-
withHeader
public RsFluent withHeader(CharSequence header)
With this header.- Parameters:
header
- The header- Returns:
- New fluent response
-
withHeader
public RsFluent withHeader(CharSequence key, CharSequence value)
With this header.- Parameters:
key
- Keyvalue
- Value- Returns:
- New fluent response
-
withType
public RsFluent withType(CharSequence ctype)
With this content type.- Parameters:
ctype
- Content type- Returns:
- New fluent response
-
withBody
public RsFluent withBody(CharSequence body)
With this body.- Parameters:
body
- Body- Returns:
- New fluent response
-
withBody
public RsFluent withBody(byte[] body)
With this body.- Parameters:
body
- Body- Returns:
- New fluent response
-
withBody
public RsFluent withBody(InputStream body)
With this body.- Parameters:
body
- Body- Returns:
- New fluent response
-
-