Friday, December 25, 2009

JSF Life cycle Tip # 1

Usually people think that by setting the attribute "immediate" true, bypasses the validation life cycle but this is not true in every case. If you talk about CommandButton and CommandLink, then its true and after "Apply Request Values" phase, request processing cycle shifts to "Render Response" phase thus skipping "Process Validation","Update Model Values", and "Invoke Application". ActionListener and action method associcated with CommandButton / CommandLink is executed in "Apply Request Values".
When we talk about editableValueHolder like InputText, and other controls, setting immediate "true" does not bypass the validation or other phases. Infact it just prioritize the control for validation e.g. if you want to validate one input control first than others, then you can set "immediate" for that control to "true".

3 comments:

gagan said...

please explain with an example....

Steve Smith said...

Great and Useful Article.

JSF Online Training

JSF Training

JSF Interview Questions

JSF Tutorials

Java Training Institutes in Chennai

Java Training in Chennai

priya said...

This is quite educational arrange. It has famous breeding about what I rarity to vouch. Colossal proverb. This trumpet is a famous tone to nab to troths. Congratulations on a career well achieved. This arrange is synchronous s informative impolites festivity to pity. I appreciated what you ok extremely here 
Data Science Course in Indira nagar
Data Science Course in btm layout
Python course in Kalyan nagar
Data Science course in Indira nagar
Data Science Course in Marathahalli
Data Science Course in BTM Layout
Data science course in bangalore