You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Document that ModelMap is not a supported argument type in WebFlux
Prior to this commit, the "Method Arguments" documentation for WebFlux
in the reference manual stated that WebFlux controller methods can
accept arguments of type Map, Model, or ModelMap to access the model.
However, ModelMap is actually not supported and results in exception
due to a type mismatch.
This commit updates the documentation to reflect this.
In addition, this commit updates related Javadoc and tests to avoid
mentioning or using ModelMap in WebFlux.
Closesgh-33107
Copy file name to clipboardExpand all lines: framework-docs/modules/ROOT/pages/web/webflux/controller/ann-methods/arguments.adoc
+1-1
Original file line number
Diff line number
Diff line change
@@ -77,7 +77,7 @@ and others) and is equivalent to `required=false`.
77
77
| For access to a part in a `multipart/form-data` request. Supports reactive types.
78
78
See xref:web/webflux/controller/ann-methods/multipart-forms.adoc[Multipart Content] and xref:web/webflux/reactive-spring.adoc#webflux-multipart[Multipart Data].
79
79
80
-
| `java.util.Map`, `org.springframework.ui.Model`, and `org.springframework.ui.ModelMap`.
80
+
| `java.util.Map` or `org.springframework.ui.Model`
81
81
| For access to the model that is used in HTML controllers and is exposed to templates as
Copy file name to clipboardExpand all lines: spring-webflux/src/test/java/org/springframework/web/reactive/result/method/annotation/SessionAttributesHandlerTests.java
Copy file name to clipboardExpand all lines: spring-webflux/src/test/java/org/springframework/web/reactive/result/view/freemarker/FreeMarkerMacroTests.java
Copy file name to clipboardExpand all lines: spring-webflux/src/test/java/org/springframework/web/reactive/result/view/freemarker/FreeMarkerViewTests.java
+4-7
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
/*
2
-
* Copyright 2002-2023 the original author or authors.
2
+
* Copyright 2002-2024 the original author or authors.
3
3
*
4
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
5
* you may not use this file except in compliance with the License.
0 commit comments