-
Notifications
You must be signed in to change notification settings - Fork 38.4k
Allow binding all MultipartFile instances as handler method argument [SPR-17405] #21938
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Rossen Stoyanchev commented So basically support |
Oliver Drotbohm commented I thought of a dedicated type as the reference documentation suggests that |
Rossen Stoyanchev commented Yes but we do support Map arguments annotated with |
Oliver Drotbohm commented Ah, that's interesting. Might be a good addition to the table of supported handler method types. |
Juergen Hoeller commented Good point, a simple I'll try to sort this out for 5.1.2 still, probably as |
Rossen Stoyanchev commented
|
Juergen Hoeller commented I've added support for |
Oliver Drotbohm opened SPR-17405 and commented
For cases in which the names of the files of a multipart request are not static but need to be dynamically calculated, it would be cool if there was a
MultipartFiles
object available for injection into a Spring MVC controller method similar to what we have withHttpHeaders
.The use case is to find a JSON document under a well known parameter name in a multipart request that then in turn contains the parameter names under which to lookup the files.
Using
someMethod(@RequestParam("json") SomeModel model, MultipartHttpServletRequest request)
already works but feels quite low level, especially if all you're interested in are the files.Issue Links:
Referenced from: commits f0f1979
0 votes, 6 watchers
The text was updated successfully, but these errors were encountered: