Using partial triggers
In order to provide a dynamic and responsive web application and make changes from the server side to the client side, a technique emerged back in 2007 called Ajax that is still being used up to this moment.
In ADF Faces, Ajax is implemented under a different umbrella called PPR. During PPR, the JSF page's life cycle is run only for certain components in the page and doesn't submit the whole page. The best part about it is that you can use PPR declaratively without the need for a single line of code.
In this recipe, we will create two cascading selectOneChoice
options, which represent regions and countries respectively; when you change the region, the countries get filtered based on the region selected.
The model of this application has been created for you. You can open it by cloning the ADFFacesPartialTriggers
application from the Git repository.
How to do it…
To learn how to use PPR, follow the ensuing steps:
Open the
ADFFacesPartialTriggers
application.Double-click on...