public static class ChunkedContent.ChunkedContentBuilder extends Object
| Constructor and Description |
|---|
ChunkedContentBuilder(String message)
Set message.
|
| Modifier and Type | Method and Description |
|---|---|
ChunkedContent.ChunkedContentBuilder |
allowPartialContent(HeaderCapture headerCapture)
Setting this will make the Response handle range headers properly.
|
com.xebialabs.restito.semantics.Action |
build()
Builds Action.
|
ChunkedContent.ChunkedContentBuilder |
delayBetweenChunks(Duration delay)
Set delay between sending each character of the message in milliseconds.
|
ChunkedContent.ChunkedContentBuilder |
fail(int numberOfFailures)
Number of times to fail (simulate network disconnect) after sending the first character.
|
public ChunkedContentBuilder(String message)
message - Message to be sent in the response.public ChunkedContent.ChunkedContentBuilder delayBetweenChunks(Duration delay)
delay - Time to wait between sending each character of the message.public ChunkedContent.ChunkedContentBuilder fail(int numberOfFailures)
numberOfFailures - Number of times to fail (simulate network disconnect) after sending
the first character. Once this number is reached, the message will send successfully.public ChunkedContent.ChunkedContentBuilder allowPartialContent(HeaderCapture headerCapture)
headerCapture - HeaderCapture object that contains the request's headers.public com.xebialabs.restito.semantics.Action build()
This work is licensed under a Creative Commons Attribution 4.0 International License.