Package spark
Class ModelAndView
java.lang.Object
spark.ModelAndView
Model And View class is used to set the name of the view and the model object
to be rendered.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionModelAndView
(Object model, String viewName) Constructs an instance with the provided model and view name -
Method Summary
-
Field Details
-
model
Model object. -
viewName
View name used to render output.
-
-
Constructor Details
-
ModelAndView
Constructs an instance with the provided model and view name- Parameters:
model
- the modelviewName
- the view name
-
-
Method Details
-
getModel
- Returns:
- the model object
-
getViewName
- Returns:
- the view name
-