public interface ViewService
View
instances. The UIF
interacts with this service from the client layer to pull information from the View dictionary
and manage the View instance through its lifecycleModifier and Type | Method and Description |
---|---|
void |
buildView(View view,
Object model,
Map<String,String> parameters)
Executes the view lifecycle on the given
View instance which will
prepare it for rendering |
View |
getViewById(String viewId)
Returns the
View entry identified by the given id |
View |
getViewByType(UifConstants.ViewType viewType,
Map<String,String> parameters)
Retrieves the
View instance that is of the given view type and matches the
given parameters (that are applicable for that type). |
String |
getViewIdForViewType(UifConstants.ViewType viewType,
Map<String,String> parameters)
Retrieves the view id for the view associated with the given view type and view type parameters
|
ViewTypeService |
getViewTypeService(UifConstants.ViewType viewType) |
View getViewById(String viewId)
View
entry identified by the given id
The id matches the id configured for the View through the dictionary. A new view instance is returned that is in the created state
viewId
- - unique id for view configured on its definitionView getViewByType(UifConstants.ViewType viewType, Map<String,String> parameters)
View
instance that is of the given view type and matches the
given parameters (that are applicable for that type). If more than one views exists for the
type and parameters, the view type may choose a default or throw an exception
If a view if found for the type parameters, a new instance is returned that is in the created state
viewType
- - name that identifies the view typeparameters
- - Map of parameter key/value pairs that are used to select the
view, the parameters allowed depend on the view typeString getViewIdForViewType(UifConstants.ViewType viewType, Map<String,String> parameters)
viewType
- name that identifies the view typeparameters
- Map of parameter key/value pairs that are used to select the
view, the parameters allowed depend on the view typevoid buildView(View view, Object model, Map<String,String> parameters)
View
instance which will
prepare it for rendering
Any configuration sent through the options Map is used to initialize the View. This map contains present options the view is aware of and will typically come from request parameters. e.g. For maintenance Views there is the maintenance type option (new, edit, copy)
After view retrieval, applies updates to the view based on the model data which Performs dynamic generation of fields (such as collection rows), conditional logic, and state updating (conditional hidden, read-only, required).
view
- - view instance that should be builtmodel
- - object instance containing the view dataparameters
- - Map of key values pairs that provide configuration for the
View
, this is generally comes from the request
and can be the request parameter Map itself. Any parameters
not valid for the View will be filtered outViewTypeService getViewTypeService(UifConstants.ViewType viewType)
Copyright © 2005–2016 The Kuali Foundation. All rights reserved.