What does it mean that "model implicitly enriched with command object"
and also the "results of @ModelAttribute annotated reference data
accessor methods"?
Command objects are objects created by Spring from request parameters. In other words, say you had
public ModelAndView doSomething(SomeFoo foo, @ModelAttribute SomeBar bar) {
return new ModelAndView("view-name");
}
Spring would implicitly add the objects foo and bar are referencing to the ModelAndView returned. Note that, although SomeFoo is not annotated with @ModelAttribute, Spring will still consider it a model attribute. You'll have to look into HandlerMethodArgumentResolver to understand why.
You can also annotate methods with @ModelAttribute and those will be called and the object created added to the Model on each request handled by the @Controller your method is in. That is what is meant by results of @ModelAttribute annotated reference data accessor methods.
How the view name is determined in Spring here?
It tells you exactly how it is determined: it uses RequestToViewNameTranslator, where the default is DefaultRequestToViewNameTranslator. Read the javadoc for more details.
Same is the case here, how the view name is determined?
Same as above.
To answer the question in your comment, Spring registers a number of HandlerMethodArgumentResolver instances to resolve the arguments to pass to your @RequestMapping annotated method. It registers them in a specific order prioritizing parameters of specific types like Model, ModelMap, ModelAndView, etc. and then annotated parameters (eg. handlers for @PathVariable, @RequestParam, etc.). Spring then iterates through this list and uses the first one it finds that can handle the parameter.
One of these HandlerMethodArgumentResolver is ServletModelAttributeMethodProcessor which handles @ModelAttribute annotated parameters. Spring registers two (2) of these. One for parameters actually annotated with @ModelAttribute and one for parameters not annotated. This way you can inject your own HandlerMethodArgumentResolver to handle parameters your way.
Registration order of HandlerMethodArgumentResolver
...
ServletModelAttributeMethodProcessor for @ModelAttribute annotated parameters
...
your own HandlerMethodArgumentResolver
...
ServletModelAttributeMethodProcessor for parameters not annotated with ModelAttribute