Skip to content

Commit de52090

Browse files
committed
Polishing contribution
Closes gh-34554
1 parent 4d862b8 commit de52090

File tree

4 files changed

+11
-23
lines changed

4 files changed

+11
-23
lines changed

framework-docs/modules/ROOT/pages/web/webflux/controller/ann-methods/return-types.adoc

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,7 @@ Controllers can then return a `Flux<List<B>>`; Reactor provides a dedicated oper
3434
| `HttpHeaders`
3535
| For returning a response with headers and no body.
3636

37-
| `ErrorResponse`
38-
| To render an RFC 9457 error response with details in the body,
39-
see xref:web/webflux/ann-rest-exceptions.adoc[Error Responses]
40-
41-
| `ProblemDetail`
37+
| `ErrorResponse`, `ProblemDetail`
4238
| To render an RFC 9457 error response with details in the body,
4339
see xref:web/webflux/ann-rest-exceptions.adoc[Error Responses]
4440

framework-docs/modules/ROOT/pages/web/webmvc/mvc-controller/ann-exceptionhandler.adoc

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -177,13 +177,9 @@ the content negotiation during the error handling phase will decide which conten
177177
be converted through `HttpMessageConverter` instances and written to the response.
178178
See xref:web/webmvc/mvc-controller/ann-methods/responseentity.adoc[ResponseEntity].
179179

180-
| `ErrorResponse`
180+
| `ErrorResponse`, `ProblemDetail`
181181
| To render an RFC 9457 error response with details in the body,
182-
see xref:web/webmvc/mvc-ann-rest-exceptions.adoc[Error Responses]
183-
184-
| `ProblemDetail`
185-
| To render an RFC 9457 error response with details in the body,
186-
see xref:web/webmvc/mvc-ann-rest-exceptions.adoc[Error Responses]
182+
see xref:web/webmvc/mvc-ann-rest-exceptions.adoc[Error Responses]
187183

188184
| `String`
189185
| A view name to be resolved with `ViewResolver` implementations and used together with the

framework-docs/modules/ROOT/pages/web/webmvc/mvc-controller/ann-methods/return-types.adoc

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,7 @@ supported for all return values.
2222
| `HttpHeaders`
2323
| For returning a response with headers and no body.
2424

25-
| `ErrorResponse`
26-
| To render an RFC 9457 error response with details in the body,
27-
see xref:web/webmvc/mvc-ann-rest-exceptions.adoc[Error Responses]
28-
29-
| `ProblemDetail`
25+
| `ErrorResponse`, `ProblemDetail`
3026
| To render an RFC 9457 error response with details in the body,
3127
see xref:web/webmvc/mvc-ann-rest-exceptions.adoc[Error Responses]
3228

spring-web/src/main/java/org/springframework/web/bind/annotation/ExceptionHandler.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -71,24 +71,24 @@
7171
*
7272
* <p>The following return types are supported for handler methods:
7373
* <ul>
74-
* <li>A {@code ModelAndView} object (from Servlet MVC).
75-
* <li>A {@link org.springframework.ui.Model} object, with the view name implicitly
74+
* <li>{@code ModelAndView} object (from Servlet MVC).
75+
* <li>{@link org.springframework.ui.Model} object, with the view name implicitly
7676
* determined through a {@link org.springframework.web.servlet.RequestToViewNameTranslator}.
77-
* <li>A {@link java.util.Map} object for exposing a model,
77+
* <li>{@link java.util.Map} object for exposing a model,
7878
* with the view name implicitly determined through a
7979
* {@link org.springframework.web.servlet.RequestToViewNameTranslator}.
80-
* <li>A {@link org.springframework.web.servlet.View} object.
81-
* <li>A {@link String} value which is interpreted as view name.
80+
* <li>{@link org.springframework.web.servlet.View} object.
81+
* <li>{@link String} value which is interpreted as view name.
8282
* <li>{@link ResponseBody @ResponseBody} annotated methods (Servlet-only)
8383
* to set the response content. The return value will be converted to the
8484
* response stream using
8585
* {@linkplain org.springframework.http.converter.HttpMessageConverter message converters}.
86-
* <li>An {@link org.springframework.http.HttpEntity HttpEntity&lt;?&gt;} or
86+
* <li>{@link org.springframework.http.HttpEntity HttpEntity&lt;?&gt;} or
8787
* {@link org.springframework.http.ResponseEntity ResponseEntity&lt;?&gt;} object
8888
* (Servlet-only) to set response headers and content. The ResponseEntity body
8989
* will be converted and written to the response stream using
9090
* {@linkplain org.springframework.http.converter.HttpMessageConverter message converters}.
91-
* <li>A {@link org.springframework.http.ProblemDetail} or {@link org.springframework.web.ErrorResponse}
91+
* <li>{@link org.springframework.http.ProblemDetail} or {@link org.springframework.web.ErrorResponse}
9292
* object to render an RFC 9457 error response with details in the body.
9393
* <li>{@code void} if the method handles the response itself (by
9494
* writing the response content directly, declaring an argument of type

0 commit comments

Comments
 (0)