@Name(value="jsfResetActions") @Scope(value=EVENT) public class JSFResetActionsBean extends Object
Resets are done using the following rule:
ResettableComponent
interface, its method
ResettableComponent.resetCachedModel()
is calledEditableValueHolder
, its submitted value is reset, and its local value is
reset only if it holds a value binding for the "value" attributeValueHolder
, its its local value is reset only if it holds a value binding
for the "value" attribute.Modifier and Type | Field and Description |
---|---|
protected String |
baseComponentId
Base component id for reset actions.
|
Constructor and Description |
---|
JSFResetActionsBean() |
Modifier and Type | Method and Description |
---|---|
String |
getBaseComponentId()
Returns the base component id, if
setBaseComponentId(String) was previously called in the same request,
or null. |
protected String |
getStringAttribute(javax.faces.component.UIComponent component,
String name,
boolean required) |
void |
resetComponent(javax.faces.component.UIComponent component)
Resets the given component.
|
protected void |
resetComponent(javax.faces.component.UIComponent comp,
boolean recursive) |
void |
resetComponentResursive(javax.faces.component.UIComponent parent)
Resets the given component and its children recursively.
|
void |
resetComponents(javax.faces.event.ActionEvent event)
Looks up the parent naming container for the component source of the action event, and reset components
recursively within this container.
|
void |
resetComponents(javax.faces.event.AjaxBehaviorEvent event)
Looks up the parent naming container for the component source of the action event, and reset components
recursively within this container.
|
protected void |
resetComponents(javax.faces.event.FacesEvent event) |
void |
resetComponentsFor(javax.faces.event.ActionEvent event)
Looks up the parent naming container for the component source of the action event, and reset components
recursively within this container.
|
void |
resetComponentsFor(javax.faces.event.AjaxBehaviorEvent event)
Looks up the parent naming container for the corresponding ajax behavior event, and reset components recursively
within this container.
|
protected void |
resetComponentsFor(javax.faces.event.FacesEvent event) |
void |
setBaseComponentId(String baseComponentId)
Sets the base component id so that
resetComponentsFor(ActionEvent) can look it up in the hierarchy of
components, and reset component states recursively from it. |
protected String baseComponentId
public JSFResetActionsBean()
public String getBaseComponentId()
setBaseComponentId(String)
was previously called in the same request,
or null.public void setBaseComponentId(String baseComponentId)
resetComponentsFor(ActionEvent)
can look it up in the hierarchy of
components, and reset component states recursively from it.resetComponentsFor(ActionEvent)
public void resetComponentsFor(javax.faces.event.ActionEvent event)
public void resetComponentsFor(javax.faces.event.AjaxBehaviorEvent event)
protected void resetComponentsFor(javax.faces.event.FacesEvent event)
protected String getStringAttribute(javax.faces.component.UIComponent component, String name, boolean required)
public void resetComponents(javax.faces.event.ActionEvent event)
public void resetComponents(javax.faces.event.AjaxBehaviorEvent event)
protected void resetComponents(javax.faces.event.FacesEvent event)
public void resetComponent(javax.faces.component.UIComponent component)
Does not reset the component children.
public void resetComponentResursive(javax.faces.component.UIComponent parent)
protected void resetComponent(javax.faces.component.UIComponent comp, boolean recursive)
Copyright © 2016 Nuxeo SA. All rights reserved.