17 May, 2015

OAF: Parameters


Oracle Application Framework (OAF) can pass parameters between pages and there are three types of parameters
1- Request
The scope of request parameters is finalized after  HTTP request.

Examples of Request Parameters
  • URL Parameters
  • Input Bean values (Message Text Input, Choice , Check etc) and Hidden Field Values (form values) in case of post
  • Event triggering bean and the action in case of post.

Request values are accessed using OAPageContext.getParameter() method.

2- Transaction
Transaction has wider scope than Request which finalize with ending of database transaction.

You can create transaction parameter using OAPageContext.putTransactionValue() , ((OADBTransactionImpl)getTransaction()).putValue() .

Get transaction parameter values using OAPageContext.getTransactionValue() , ((OADBTransactionImpl)getTransaction()).getValue()

3- Session
Session has wider scope than Transaction which his life time is until user log out from application.

You can create Session parameter using OAPageContext.putSessionValue() ,  OAPageContext.putSessionValueDirect() .
 
Get transaction Session values using OAPageContext.getSessionValue();


URL Parameters Encryption and Encoding
We can encrypt parameters when  passing in URL in the following formats
1- {@Attr}  encodes. Changes Mahmoud Elsayed to Mahmoud %Elsayed
2- {!Attr} encrypts parameter value, Get parameter value in Controller using OAPageContext.getDecryptedParameter()
3- {$Attr} plain token substitution (no encoding or encryption), Get parameter value in Controller using OAPageContext.getParameter()
 
Global parameters in URL
1- {@@RETURN_TO_MENU}  Used for E-Business Suite Personal Home Page. Same as OAWebBeanConstants.RETURN_TO_MENU_URL.

2- {@@RETURN_TO_PORTAL} - Return the user to a launching Portal page. Same as OAWebBeanConstants.RETURN_TO_PORTAL_URL.


Thanks

No comments:

Post a Comment

ADF : Scope Variables

Oracle ADF uses many variables and each variable has a scope. There are five scopes in ADF (Application, Request, Session, View and PageFl...