Monday, April 18, 2011

What Scope to be used @ ADF

Page flow scope: When you need to pass data values between activities within a task flow.

View scope: Recommended for variables that are needed only within the current view activity, not across view activities.

Request scope: Should be used when the scope does not need to persist longer than the current request. It is the only scope that should be used to store UI component information.
Backing bean scope:  Must be used for backing beans in your task flow if there is a possibility that your task flow will appear in two region components or declarative components on the same page and you would like to achieve region instance isolations.

*Because Pageflow, Backing bean and View scope are not standard JSF scope, EL expression must explicitly include the scope to reference bean. For example, to reference the MyBean managed bean from the backing bean scope, your expression would be #{backingBeanScope.MyBean}.

No comments:

Post a Comment