oracle application framework vamshi krishna vamshi krishna

23
Oracle Oracle Application Application Framework Framework Vamshi Vamshi krishna krishna

Upload: melvyn-wilkins

Post on 21-Dec-2015

262 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Oracle Application Framework Vamshi krishna Vamshi krishna

OracleOracleApplication FrameworkApplication Framework

Vamshi krishnaVamshi krishna

Page 2: Oracle Application Framework Vamshi krishna Vamshi krishna

Topics:

Introduction to OAF Pre-requisites for learning OAF OAF Architecture JDeveloper tool & Versions Steps to Develop/Customize of OAF pages Registration OAF pages in Oracle Applications11i.

Page 3: Oracle Application Framework Vamshi krishna Vamshi krishna

Introduction to OAF

Oracle Applications Framework is the Oracle Applications development and deployment platform for HTML-based business applications

OA Framework consists of a set of middle-tier runtime services and a design-time extension to Oracle9i JDeveloper called Oracle Applications Extension (OA Extension).

Page 4: Oracle Application Framework Vamshi krishna Vamshi krishna

Introduction to OAF…..(Contd..)

End User Productivity Enterprise-Grade Performance and Scalability Developer Productivity Application Customizability Open Standards

Page 5: Oracle Application Framework Vamshi krishna Vamshi krishna

Pre-requisites for learning OAF

You need to have an Oracle Apps 11i or higher environment to play around with.

Basic knowledge of java is needed. Rather I would say basic knowledge of OOP [Object Oriented Programming] is needed. I mean just the concepts.

Understand MVC concept.

Page 6: Oracle Application Framework Vamshi krishna Vamshi krishna

OAF Architecture

Model View Controller ( MVC), its over view

Page 7: Oracle Application Framework Vamshi krishna Vamshi krishna

OAF Architecture…(Contd…)

Page 8: Oracle Application Framework Vamshi krishna Vamshi krishna

OAF Architecture…(Contd…)

Overview of Model The Model is where the application implements its business logic The model component is implemented using the BC4J.BC4J Consists of

three components• Entity Object and Associations.• View Object and View Link objects.• Application Module. Entity Object and Associations : Entity Objects represents a database row in

middle-tire. Database rows are represented as individual entities, in which attributes typically corresponds to columns in the corresponding table to automatically implement queries,inserts,updates and deletes.

Entity objects can also be based on views, synonyms or snapshots. most entity objects that you create subclass that: oracle.apps.fnd.framework.server.OAEntityImpl; Associations are used to establish the relationship between the entity

objects. When you create an entity object, framework will provide you a java class

with the setter and getter methods corresponding to each column of the table to which you are entity object is based on.

Page 9: Oracle Application Framework Vamshi krishna Vamshi krishna

OAF Architecture…(Contd…)

View Objects

view object accesses the result set of a sql statement. It can be either based on the entity object or on plain sql query. All view objects

that you create subclass the Oracle.apps.fnd.framework.server.OAViewObjectImpl.

Application Module A logical container that manages and provides access to related BC4J

model objects. All application modules that you create subclass the Oracle.apps.fnd.framework.server.OAApplicationModuleImpl

Page 10: Oracle Application Framework Vamshi krishna Vamshi krishna

OAF Architecture…(Contd…)

The View : The OA Framework View is implemented using UI XML (UIX). UIX

uses XML to describe the components and hierarchy that make up an application page. UIX also provides runtime capabilities to translate that metadata into HTML output so that it can be shown on a Browser or a mobile device.

The metadata used to describe the UI is loaded into a database repository, called Meta Data Services (MDS), at deployment time and optionally at design time as well.

The Controller: The Controller responds to user action and direct aplication flow. It

provides the writing between the UIX web bean and the middle-tier.All the controllers that we create subclass the oracle.apps.fnd.framework.webui.OAControllerImpl.

The controller will request from HTTP Get and Http Post.

Page 11: Oracle Application Framework Vamshi krishna Vamshi krishna

OAF Architecture…(Contd…)

Controller Methods Process Request Process Form Data Process Form RequestProcess Request: This phase is invoked upon a browser ‘Get’ or redirect/forward. This is where custom

code can call the application module to intialize and query the data. this phase may optionally construct or modify the web beans to create or alter the page structure and web bean properties.

Process Form Data: This phase is invoked upon a browser ‘post’. During this phase the framework will

automatically applies form changes back to the underlying view objects. Rarely custom code required in this phase. if exceptions are thrown during this phase, the process form request phase is skipped and the page is redisplayed.

Process Form Request: This phase is invoked upon a browser ‘post ‘, assuming no exceptions were thrown

during the process form data phase. This is were custom code can handle the submit events call the application module to process the event.

Page 12: Oracle Application Framework Vamshi krishna Vamshi krishna

OAF Architecture…(Contd…)

Framework passes two parameters OA PageContext and OAWebBeanUsage of OA PageContext:• To get and set values of the fields, using oapagecontext.getparameter and

oapagecontext.putparameter.• For redirecting to the current page or anotherpage, for example to redirecting to

current page itself use oapagecontext.forwardimmediatelyToCurrentpage. Or you may use oapagecontext.sendRedirect.

Usage of OAWebBean: Remember that webbean represents the hierarchy/structure of components in the

page.Hence using this parameter object, you can get a handle to any bean/component in that page hierarchy.once you have a handle to that bean(say field bean or button bean), you can then invoke methods like set Rendered etc to change the behaviour of page at runtime.some examples are

1. OA WebBean LastName=oawebbean.findindexedChildRecursive(“personlastname”);

2. OAStackLayoutBean oastack=oawebbean.findindexedChildRecursive(“stackRegionName”);

Page 13: Oracle Application Framework Vamshi krishna Vamshi krishna

OAF Architecture…(Contd…)

Onion Structure of OAF

Page 14: Oracle Application Framework Vamshi krishna Vamshi krishna

BC4J File Structures

AM AND VO -> BC4J XXAAM.oracle.apps.po.xxname.server

Entity Object(EO) -> BC4J XXAAM.oracle.apps.po.xxname.schema.server LOV ->BC4JXXAAM.oracle.apps.po.xxname.LOV.server Poplist ->BC4JXXAAM.oracle.apps.po.xxname.poplist.server Controller & PageXXAAM.oracle.apps.po.xxname.webui

Page 15: Oracle Application Framework Vamshi krishna Vamshi krishna

JDeveloper tool & Versions

Jdeveloper9i is tool to develop OAF pages as well as customizations.

p4045639_11i_GENERIC – download this patch from oracle metalink.

We have three folders jdevbin,jdevdoc,jdevhome in that patch.

Setting up jdeveloper into your workstation.

Page 16: Oracle Application Framework Vamshi krishna Vamshi krishna

Development of OAF Pages.

Creating Simple Page. Creating Hellow World Page. Some sample example Pages.

Page 17: Oracle Application Framework Vamshi krishna Vamshi krishna

Development OAF Pages….(Contd..)

Search Page Automatic Search. Manual Search. Creating LOV. Creating Dropdown list.

Page 18: Oracle Application Framework Vamshi krishna Vamshi krishna

Development OAF Pages….(Contd..)

Create Page How to Use java Based EO. How to Use PL/SQL Based EO.

Page 19: Oracle Application Framework Vamshi krishna Vamshi krishna

Development OAF Pages….(Contd..)

Update Page How to use SPEL.

Page 20: Oracle Application Framework Vamshi krishna Vamshi krishna

Development OAF Pages….(Contd..)

Delete Page How to create Dialog box in OAF.

Page 21: Oracle Application Framework Vamshi krishna Vamshi krishna

Development OAF Pages….(Contd..)

How to call oracle Sql and PL/SQL in OAF

Prepare Statement. Callable Statement. Calling Oracle APIS.

Page 22: Oracle Application Framework Vamshi krishna Vamshi krishna

Register OAF Pages in Oracle Apps11i

Deploying OAF Pages into Application Transferring the related source code/files to

the Oracle APPS environment. Importing the new directory structure/path of

the page/form in the MDS repository. Registration of the page in the Oracle Apps

environment

Page 23: Oracle Application Framework Vamshi krishna Vamshi krishna

THANK YOU