Package io.micronaut.views
Class ModelAndView<T>
java.lang.Object
io.micronaut.views.ModelAndView<T>
- Type Parameters:
T
- The model type
Holder for both Model and View.
- Since:
- 1.0
- Author:
- Sergio del Amo, graemerocher
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
ModelAndView
public ModelAndView()Empty constructor. -
ModelAndView
Constructor.- Parameters:
view
- view name to be renderedmodel
- Model to be rendered against the view
-
-
Method Details
-
getView
- Returns:
- view name to be rendered
-
setView
Sets the view to use.- Parameters:
view
- the view name
-
getModel
- Returns:
- model to render
-
setModel
Sets the model to use.- Parameters:
model
- model to be rendered
-