public class BasicResponseBuilder extends AbstractResponseBuilder<BasicHttpResponse>
BasicHttpResponse
instances.Modifier | Constructor and Description |
---|---|
protected |
BasicResponseBuilder(int status) |
Modifier and Type | Method and Description |
---|---|
BasicResponseBuilder |
addHeader(Header header) |
BasicResponseBuilder |
addHeader(String name,
String value) |
BasicHttpResponse |
build() |
static BasicResponseBuilder |
copy(HttpResponse response) |
static BasicResponseBuilder |
create(int status) |
BasicResponseBuilder |
removeHeader(Header header) |
BasicResponseBuilder |
removeHeaders(String name) |
BasicResponseBuilder |
setHeader(Header header) |
BasicResponseBuilder |
setHeader(String name,
String value) |
BasicResponseBuilder |
setHeaders(Header... headers) |
BasicResponseBuilder |
setVersion(ProtocolVersion version) |
String |
toString() |
getStatus, setStatus
digest, getFirstHeader, getFirstHeaders, getHeaders, getHeaders, getLastHeader, getVersion, setHeaders
public static BasicResponseBuilder create(int status)
public static BasicResponseBuilder copy(HttpResponse response)
public BasicResponseBuilder setVersion(ProtocolVersion version)
setVersion
in class AbstractResponseBuilder<BasicHttpResponse>
public BasicResponseBuilder setHeaders(Header... headers)
setHeaders
in class AbstractResponseBuilder<BasicHttpResponse>
public BasicResponseBuilder addHeader(Header header)
addHeader
in class AbstractResponseBuilder<BasicHttpResponse>
public BasicResponseBuilder addHeader(String name, String value)
addHeader
in class AbstractResponseBuilder<BasicHttpResponse>
public BasicResponseBuilder removeHeader(Header header)
removeHeader
in class AbstractResponseBuilder<BasicHttpResponse>
public BasicResponseBuilder removeHeaders(String name)
removeHeaders
in class AbstractResponseBuilder<BasicHttpResponse>
public BasicResponseBuilder setHeader(Header header)
setHeader
in class AbstractResponseBuilder<BasicHttpResponse>
public BasicResponseBuilder setHeader(String name, String value)
setHeader
in class AbstractResponseBuilder<BasicHttpResponse>
public BasicHttpResponse build()
build
in class AbstractResponseBuilder<BasicHttpResponse>
Copyright © 2005–2021 The Apache Software Foundation. All rights reserved.