Summary
Facelet Tag name: <f:ajax>
Facelet Tag class: org.apache.myfaces.view.facelets.tag.jsf.core.AjaxHandler
This tag creates an instance of AjaxBehavior, and associates it with the nearest
parent UIComponent that implements ClientBehaviorHolder interface. This tag can
be used on single or composite components.
Unless otherwise specified, all attributes accept static values or EL expressions.
According to the documentation, the tag handler implementing this tag should meet the following conditions:
- Since this tag attach objects to UIComponent instances, and those instances implements Behavior interface, this component should implement BehaviorHolderAttachedObjectHandler interface.
- f:ajax does not support binding property. In theory we should do something similar to f:convertDateTime tag does: extends from ConverterHandler and override setAttributes method, but in this case BehaviorTagHandlerDelegate has binding property defined, so if we extend from BehaviorHandler we add binding support to f:ajax.
- This tag works as a attached object handler, but note on the api there is no component to define a target for a behavior. See comment inside apply() method.
Attributes
Name | Type | Required | Description |
---|---|---|---|
delay | javax.el.ValueExpression | false | |
disabled | javax.el.ValueExpression | false | |
event | javax.el.ValueExpression | false | |
execute | javax.el.ValueExpression | false | |
immediate | javax.el.ValueExpression | false | |
listener | javax.el.MethodExpression | false | |
onerror | javax.el.ValueExpression | false | |
onevent | javax.el.ValueExpression | false | |
render | javax.el.ValueExpression | false | |
resetValues | javax.el.ValueExpression | false |