|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.kuali.rice.krad.uif.service.impl.ViewServiceImpl
public class ViewServiceImpl
Implementation of ViewService
Provides methods for retrieving View instances and carrying out the View
lifecycle methods. Interacts with the configured ViewHelperService
during the view lifecycle
Constructor Summary | |
---|---|
ViewServiceImpl()
|
Method Summary | |
---|---|
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 |
protected DataDictionaryService |
getDataDictionaryService()
|
View |
getViewById(String viewId)
Returns the View entry identified by the given id |
View |
getViewByType(UifConstants.ViewType viewType,
Map<String,String> parameters)
Retrieves the ViewTypeService for the given view type, then builds up the index based
on the supported view type parameters and queries the dictionary service to retrieve the view
based on its type and index |
ViewTypeService |
getViewTypeService(UifConstants.ViewType viewType)
|
List<ViewTypeService> |
getViewTypeServices()
|
protected void |
performViewLifecycle(View view,
Object model,
Map<String,String> parameters)
Initializes a newly created View instance. |
void |
setDataDictionaryService(DataDictionaryService dataDictionaryService)
|
void |
setViewTypeServices(List<ViewTypeService> viewTypeServices)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ViewServiceImpl()
Method Detail |
---|
public View getViewById(String viewId)
ViewService
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
getViewById
in interface ViewService
viewId
- - unique id for view configured on its definition
ViewService.getViewById(java.lang.String)
public View getViewByType(UifConstants.ViewType viewType, Map<String,String> parameters)
ViewTypeService
for the given view type, then builds up the index based
on the supported view type parameters and queries the dictionary service to retrieve the view
based on its type and index
getViewByType
in interface ViewService
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 type
org.kuali.rice.krad.uif.service.ViewService#getViewByType(org.kuali.rice.krad.uif.UifConstants.ViewType,
java.util.Map)
public void buildView(View view, Object model, Map<String,String> parameters)
ViewService
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).
buildView
in interface ViewService
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 outorg.kuali.rice.krad.uif.service.ViewService#buildView(org.kuali.rice.krad.uif.view.View, java.lang.Object,
java.util.Map)
protected void performViewLifecycle(View view, Object model, Map<String,String> parameters)
View
instance. Each component of the tree is invoked
to perform setup based on its configuration. In addition helper service methods are invoked to
perform custom initialization
view
- - view instance to initializemodel
- - 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 outpublic ViewTypeService getViewTypeService(UifConstants.ViewType viewType)
getViewTypeService
in interface ViewService
public List<ViewTypeService> getViewTypeServices()
public void setViewTypeServices(List<ViewTypeService> viewTypeServices)
protected DataDictionaryService getDataDictionaryService()
public void setDataDictionaryService(DataDictionaryService dataDictionaryService)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |