|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.kuali.rice.krad.uif.lifecycle.ViewLifecyclePhaseBase org.kuali.rice.krad.uif.lifecycle.ApplyModelComponentPhase
public class ApplyModelComponentPhase
Lifecycle phase processing task for applying the model to a component.
During the apply model phase each component of the tree if invoked to setup any state based on the given model data
Part of the view lifecycle that applies the model data to the view. Should be called after the model has been populated before the view is rendered. The main things that occur during this phase are:
The update phase can be called multiple times for the view's lifecycle (typically only once per request)
Constructor Summary | |
---|---|
ApplyModelComponentPhase()
|
Method Summary | |
---|---|
Map<String,Object> |
getCommonContext()
Gets global objects for the context map and pushes them to the context for the component |
String |
getEndViewStatus()
Gets the expected view status after phase execution. |
ViewLifecycle.LifecycleEvent |
getEventToNotify()
Gets the event to notify on completion. |
String |
getStartViewStatus()
Gets the expected view status prior to phase execution. |
String |
getViewPhase()
Gets the view lifecycle phase constant that corresponds to this phase processing task. |
protected void |
initializePendingTasks(Queue<ViewLifecycleTask<?>> tasks)
Applies the model data to a component of the View instance |
protected ViewLifecyclePhase |
initializeSuccessor(LifecycleElement nestedElement,
String nestedPath,
Component parent)
Define all nested lifecycle components, and component prototypes, as successors. |
protected void |
prepare(LifecycleElement element,
Object model,
String path,
List<String> refreshPaths,
Component parent,
ViewLifecyclePhaseBase nextPhase,
Set<String> visitedIds)
Create a new lifecycle phase processing task for applying the model to a element. |
protected void |
recycle()
Resets this phase for recycling. |
boolean |
visit(LifecycleElement element)
Visit a lifecycle element. |
Methods inherited from class org.kuali.rice.krad.uif.lifecycle.ViewLifecyclePhaseBase |
---|
getCurrentTask, getDepth, getElement, getModel, getNestedPropertiesForRefreshPath, getParent, getParentPath, getPredecessor, getRefreshPaths, getViewPath, initializeAllLifecycleSuccessors, initializeRefreshPathSuccessors, initializeSuccessors, isComplete, isProcessed, notifyCompleted, prepare, processSuccessors, run, setViewPath, shouldSkipLifecycle, toString, trace, validateBeforeProcessing, verifyCompleted |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ApplyModelComponentPhase()
Method Detail |
---|
protected void recycle()
recycle
in class ViewLifecyclePhaseBase
protected void prepare(LifecycleElement element, Object model, String path, List<String> refreshPaths, Component parent, ViewLifecyclePhaseBase nextPhase, Set<String> visitedIds)
element
- The element the model should be applied tomodel
- Top level object containing the datapath
- The path to the element relative to the parent elementrefreshPaths
- list of paths to run lifecycle on when executing a refresh lifecycleparent
- The parent elementnextPhase
- The phase to queue directly upon completion of this phase, if applicablevisitedIds
- Tracks components ids that have been seen for adjusting duplicatespublic String getViewPhase()
UifConstants.ViewPhases
public String getStartViewStatus()
public String getEndViewStatus()
public ViewLifecycle.LifecycleEvent getEventToNotify()
ViewLifecycle.LifecycleEvent
public Map<String,Object> getCommonContext()
#prepare(LifecycleElement, Object, String, Component, ViewLifecyclePhaseBase, Set)
public boolean visit(LifecycleElement element)
element
- The lifecycle element (component or layout manager) to mark as visisted.
protected void initializePendingTasks(Queue<ViewLifecycleTask<?>> tasks)
TODO: Revise - The component is invoked to to apply the model data. Here the component can generate any additional fields needed or alter the configured fields. After the component is invoked a hook for custom helper service processing is invoked. Finally the method is recursively called for all the component children
Initializes queue of pending tasks phases.This method will be called before during processing to determine which tasks to perform at this phase.
initializePendingTasks
in class ViewLifecyclePhaseBase
tasks
- The queue of tasks to perform.protected ViewLifecyclePhase initializeSuccessor(LifecycleElement nestedElement, String nestedPath, Component parent)
initializeSuccessor
in class ViewLifecyclePhaseBase
nestedElement
- The lifecycle element.nestedPath
- The path, relative to the parent element.parent
- The parent component of the nested element.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |