Interface SdkHttpFullResponse.Builder
- All Superinterfaces:
Buildable,CopyableBuilder<SdkHttpResponse.Builder,,SdkHttpResponse> SdkBuilder<SdkHttpResponse.Builder,,SdkHttpResponse> SdkHttpHeaders,SdkHttpResponse.Builder
- Enclosing interface:
SdkHttpFullResponse
Builder for a
DefaultSdkHttpFullResponse.-
Method Summary
Modifier and TypeMethodDescriptionappendHeader(String headerName, String headerValue) Add a single header to be included in the created HTTP request.build()An immutable object that is created from the properties that have been set on the builder.Removes all headers from this builder.content()The content, exactly as it was configured withcontent(AbortableInputStream).content(AbortableInputStream content) Configure anSdkHttpFullResponse.content()to be used in the HTTP response.headers()The query parameters, exactly as they were configured withheaders(Map),putHeader(String, String)andputHeader(String, List).Configure anSdkHttpHeaders.headers()to be used in the created HTTP response.default SdkHttpFullResponse.BuilderAdd a single header to be included in the created HTTP response.Add a single header with multiple values to be included in the created HTTP response.removeHeader(String headerName) Remove all values for the requested header from this builder.intThe status text, exactly as it was configured withstatusCode(int).statusCode(int statusCode) Configure anSdkHttpResponse.statusCode()to be used in the created HTTP response.The status text, exactly as it was configured withstatusText(String).statusText(String statusText) Configure anSdkHttpResponse.statusText()to be used in the created HTTP response.Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copyMethods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutationMethods inherited from interface software.amazon.awssdk.http.SdkHttpHeaders
firstMatchingHeader, firstMatchingHeader, forEachHeader, matchingHeaders, numHeaders
-
Method Details
-
statusText
String statusText()The status text, exactly as it was configured withstatusText(String).- Specified by:
statusTextin interfaceSdkHttpResponse.Builder
-
statusText
Configure anSdkHttpResponse.statusText()to be used in the created HTTP response. This is not validated until the http response is created.- Specified by:
statusTextin interfaceSdkHttpResponse.Builder
-
statusCode
int statusCode()The status text, exactly as it was configured withstatusCode(int).- Specified by:
statusCodein interfaceSdkHttpResponse.Builder
-
statusCode
Configure anSdkHttpResponse.statusCode()to be used in the created HTTP response. This is not validated until the http response is created.- Specified by:
statusCodein interfaceSdkHttpResponse.Builder
-
headers
The query parameters, exactly as they were configured withheaders(Map),putHeader(String, String)andputHeader(String, List).- Specified by:
headersin interfaceSdkHttpHeaders- Specified by:
headersin interfaceSdkHttpResponse.Builder- Returns:
- An unmodifiable map of all headers in this message.
-
putHeader
Add a single header to be included in the created HTTP response.This completely OVERRIDES any values already configured with this header name in the builder.
- Specified by:
putHeaderin interfaceSdkHttpResponse.Builder- Parameters:
headerName- The name of the header to add (eg. "Host")headerValue- The value for the header
-
putHeader
Add a single header with multiple values to be included in the created HTTP response.This completely OVERRIDES any values already configured with this header name in the builder.
- Specified by:
putHeaderin interfaceSdkHttpResponse.Builder- Parameters:
headerName- The name of the header to addheaderValues- The values for the header
-
appendHeader
Add a single header to be included in the created HTTP request.This will ADD the value to any existing values already configured with this header name in the builder.
- Specified by:
appendHeaderin interfaceSdkHttpResponse.Builder- Parameters:
headerName- The name of the header to addheaderValue- The value for the header
-
headers
Configure anSdkHttpHeaders.headers()to be used in the created HTTP response. This is not validated until the http response is created. This overrides any values currently configured in the builder.- Specified by:
headersin interfaceSdkHttpResponse.Builder
-
removeHeader
Remove all values for the requested header from this builder.- Specified by:
removeHeaderin interfaceSdkHttpResponse.Builder
-
clearHeaders
SdkHttpFullResponse.Builder clearHeaders()Removes all headers from this builder.- Specified by:
clearHeadersin interfaceSdkHttpResponse.Builder
-
content
AbortableInputStream content()The content, exactly as it was configured withcontent(AbortableInputStream). -
content
Configure anSdkHttpFullResponse.content()to be used in the HTTP response. This is not validated until the http response is created.Implementers should implement the abort method on the input stream to drop all remaining content with the service. This is usually done by closing the service connection.
-
build
SdkHttpFullResponse build()Description copied from interface:SdkBuilderAn immutable object that is created from the properties that have been set on the builder.- Specified by:
buildin interfaceBuildable- Specified by:
buildin interfaceSdkBuilder<SdkHttpResponse.Builder,SdkHttpResponse> - Returns:
- an instance of T
-