Polish Javadoc for ClientHttpResponse

This commit is contained in:
Sam Brannen
2020-02-19 11:46:03 +01:00
parent 8ff1ac59e0
commit e029dbf607

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2019 the original author or authors.
* Copyright 2002-2020 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -24,7 +24,8 @@ import org.springframework.http.HttpStatus;
/**
* Represents a client-side HTTP response.
* Obtained via an calling of the {@link ClientHttpRequest#execute()}.
*
* <p>Obtained via an invocation of {@link ClientHttpRequest#execute()}.
*
* <p>A {@code ClientHttpResponse} must be {@linkplain #close() closed},
* typically in a {@code finally} block.
@@ -35,7 +36,9 @@ import org.springframework.http.HttpStatus;
public interface ClientHttpResponse extends HttpInputMessage, Closeable {
/**
* Return the HTTP status code as an {@link HttpStatus} enum value.
* Get the HTTP status code as an {@link HttpStatus} enum value.
* <p>For status codes not supported by {@code HttpStatus}, use
* {@link #getRawStatusCode()} instead.
* @return the HTTP status as an HttpStatus enum value (never {@code null})
* @throws IOException in case of I/O errors
* @throws IllegalArgumentException in case of an unknown HTTP status code
@@ -45,7 +48,7 @@ public interface ClientHttpResponse extends HttpInputMessage, Closeable {
HttpStatus getStatusCode() throws IOException;
/**
* Return the HTTP status code (potentially non-standard and not
* Get the HTTP status code (potentially non-standard and not
* resolvable through the {@link HttpStatus} enum) as an integer.
* @return the HTTP status as an integer value
* @throws IOException in case of I/O errors
@@ -56,7 +59,7 @@ public interface ClientHttpResponse extends HttpInputMessage, Closeable {
int getRawStatusCode() throws IOException;
/**
* Return the HTTP status text of the response.
* Get the HTTP status text of the response.
* @return the HTTP status text
* @throws IOException in case of I/O errors
*/