public class ModelAndView extends Object
Modifier and Type | Field and Description |
---|---|
Map<String,Object> |
model
View data.
|
String |
view
View name.
|
Constructor and Description |
---|
ModelAndView(String view)
Creates a new model and view.
|
ModelAndView(String view,
Map<String,Object> model)
Creates a new model and view.
|
Modifier and Type | Method and Description |
---|---|
ModelAndView |
put(Map<String,Object> attributes)
Copy all the attributes into the model.
|
ModelAndView |
put(String name,
Object value)
Put a model attribute.
|
String |
toString() |
public final String view
public ModelAndView(@Nonnull String view, @Nonnull Map<String,Object> model)
view
- View name.model
- View model.public ModelAndView put(@Nonnull String name, Object value)
name
- Name.value
- Value.public ModelAndView put(@Nonnull Map<String,Object> attributes)
attributes
- Attributes.Copyright © 2019. All rights reserved.