/** * Builds a new full response based on the settings configured in this builder. * If {@code validate} is set to true: * <ul> * <li>an exception will be thrown if the content length is not an integer, or more than one content length exists</li> * </ul> * * @return a new full response */ public StreamingHttpResponse build() { if (validate) { ensureContentLengthIsValid(); } return new StreamingHttpResponse(this); }