Class MarshaledResponse.Builder

java.lang.Object
com.soklet.MarshaledResponse.Builder
Enclosing class:
MarshaledResponse

@NotThreadSafe public static final class MarshaledResponse.Builder extends Object
Builder used to construct instances of MarshaledResponse via MarshaledResponse.withResponse(Response) or MarshaledResponse.withStatusCode(Integer).

Known-length bodies and streaming bodies are mutually exclusive. This builder does not automatically clear one when the other is set; use withoutBody() or withoutStream() before build() when switching body modes.

This class is intended for use by a single thread.

Author:
Mark Allen