oaf developer guide 13.1.3

1737
Oracle Application Framework Developer's Guide Release 12.1.3 July 2010

Upload: crwanare

Post on 01-Nov-2014

12.729 views

Category:

Technology


5 download

DESCRIPTION

 

TRANSCRIPT

  • 1. Oracle Application Framework Developers Guide Release 12.1.3 July 2010
  • 2. Table of ContentsORACLE APPLICATION FRAMEWORK DEVELOPERS GUIDE, RELEASE 12.1.3.................................17 Preface .................................................................................................................................17 Oracle Application Framework Support Guidelines for Customers ................................20CHAPTER 1: GETTING STARTED ..................................................................................................25 Introduction to OA Framework ...........................................................................................25 Setting Up Your Development Environment ......................................................................33 Customer, Consultant or Support Representative Using JDeveloper on Windows ............ 33 Customer, Consultant or Support Representative Using JDeveloper on Linux .................. 36 Building and Running Hello, World! .................................................................................40 OA Framework Development Runtime Configuration.......................................................71CHAPTER 2: OA FRAMEWORK ESSENTIALS .................................................................................75 JSP Application Primer .......................................................................................................75 Anatomy of an OA Framework Page ..................................................................................86 Page Basics ...................................................................................................................... 86 The Model ......................................................................................................................... 87 The View........................................................................................................................... 92 The Controller ................................................................................................................... 98 Web Bean Architecture ................................................................................................... 103 Guide to OA Framework Javadoc ................................................................................... 105 OA Framework State Management ...................................................................................109 Architectural Overview .................................................................................................... 109 Root Application Modules (Database Session and Transaction State) ............................ 110 Servlet Session ............................................................................................................... 115 3
  • 3. Oracle Application Framework Developers Guide Oracle E-Business Suite User Session ........................................................................... 116 Page Context .................................................................................................................. 117 Request .......................................................................................................................... 120 State Persistence Model (Passivation) .......................................................................... 122 Application Module Pooling ............................................................................................. 122CHAPTER 3: BUILDING AN OA FRAMEWORK APPLICATION (THE BASICS) ....................................125 Implementing the Model....................................................................................................125 Designing Model Objects ................................................................................................ 125 Recommended Build Approach ...................................................................................... 127 Business Components Packages.................................................................................... 128 Entity Objects.................................................................................................................. 128 Entity Associations (Association Objects) ....................................................................... 135 View Objects and View Rows ......................................................................................... 138 View Links ...................................................................................................................... 147 Application Modules ........................................................................................................ 150 Entity Objects, Entity Experts, Validation Application Modules and Validation View Objects ........................................................................................................................... 165 Validation View Objects ............................................................................................... 165 Validation Application Modules (VAMs) ....................................................................... 165 Entity Experts .............................................................................................................. 166 Reusing Business Objects .............................................................................................. 167 Implementing the View ......................................................................................................169 Designing the User Interface........................................................................................... 169 Pages ............................................................................................................................. 170 Reusable Components ................................................................................................... 1724
  • 4. Table of Contents Attribute Sets .................................................................................................................. 176 URL Parameters: Tokens, Encryption, Encoding ............................................................ 180 Style Sheets ................................................................................................................... 182 Accessibility .................................................................................................................... 183 Internationalization .......................................................................................................... 183 Model Interaction ............................................................................................................ 184 Menus and Page Security ............................................................................................... 191Implementing the Controller .............................................................................................196 Designing an OA Controller ............................................................................................ 196 Creating an OA Controller ............................................................................................... 199 Handling an HTTP GET .................................................................................................. 202 Modifying Bean Properties .......................................................................................... 204 Creating Beans Programmatically ............................................................................... 206 Handling an HTTP POST (Form Submit) ........................................................................ 209 Model Interaction ............................................................................................................ 213 Disabling Validation ........................................................................................................ 218 Javascript ....................................................................................................................... 220Error Handling ...................................................................................................................221Creating Attribute Sets......................................................................................................239 Designing Attribute Sets ................................................................................................. 239 Creating Attribute Set Packages Manually ...................................................................... 240 Creating Attribute Sets Manually ..................................................................................... 240 Generating Attribute Sets Automatically (Only on Linux) ................................................. 240Internationalization............................................................................................................246 5
  • 5. Oracle Application Framework Developers Guide User Preferences ............................................................................................................ 246 Language........................................................................................................................ 247 Timezone ........................................................................................................................ 248 Client Character Encoding .............................................................................................. 249 Date and Time ................................................................................................................ 249 Numbers/Currency .......................................................................................................... 252 Text and Component Alignment ...................................................................................... 255 Localized Layouts ........................................................................................................... 256 Calendar Support............................................................................................................ 256 Character Encoding of BC4J XML Files .......................................................................... 258 Files in a Typical OA Framework Application..................................................................259CHAPTER 4: IMPLEMENTING SPECIFIC UI FEATURES ..................................................................263 Accelerator Keys (Hot Keys) ...........................................................................................263 Attachments .......................................................................................................................266 Auto-Repeating Layout (ARL) ...........................................................................................300 BI Publisher Integration - Printing A Report From Within an OA Framework Page ......305 Bound Values ....................................................................................................................307 Branding.............................................................................................................................318 Bulleted List .......................................................................................................................325 Buttons (Action/Navigation) .............................................................................................329 Buttons (Global) ................................................................................................................342 Charts and Graphs ............................................................................................................352 Component-Level Function Security (Dynamic User Interface) .....................................381 Concurrent Processing: Request Submission and Monitoring......................................4096
  • 6. Table of ContentsContent Containers ...........................................................................................................416Contextual Information .....................................................................................................420Controlling UIX Rendering Output ...................................................................................423Custom HTML ....................................................................................................................427Daily Business Intelligence / OA Framework Integration ...............................................431Data Export ........................................................................................................................436Date Picker .........................................................................................................................443Declarative Page Flow .......................................................................................................449Dialog Pages ......................................................................................................................465Dynamic User Interface .....................................................................................................381File Upload and Download ................................................................................................470Flexfields ............................................................................................................................475Forms / OA Framework Page Integration.........................................................................508Headers and Subheaders ..................................................................................................512HGrid ..................................................................................................................................520Hide/Show ..........................................................................................................................539Images in Your Pages .......................................................................................................551Include Content (URL and Servlet) ...................................................................................560Inline Messaging, Tips, Hints and Bubble Text ...............................................................563Instruction Text..................................................................................................................569Links ...................................................................................................................................572List of Values (LOV) ..........................................................................................................576Locator Element: Breadcrumbs .......................................................................................606Locator Element: Page/Record Navigation......................................................................620 7
  • 7. Oracle Application Framework Developers Guide Locator Element: Train......................................................................................................632 Message Box .....................................................................................................................637 Mobile Applications...........................................................................................................642 Notifications (Workflow Worklist).....................................................................................643 Page Access Tracking.......................................................................................................647 Page Contents Bottom Line (the Ski) .............................................................................650 Page Footer........................................................................................................................652 Page Layout (How to Place Content) ...............................................................................655 Page Security .....................................................................................................................676 Page Stamps ......................................................................................................................686 Partial Page Rendering (Dynamic User Interface) ...........................................................381 Personalizable Pages ........................................................................................................691 Creating a Configurable Page ......................................................................................... 691 Creating an End-User Personalizable Page .................................................................... 708 Developer Information for Admin-Level Personalizations ................................................ 709 OA Framework Personalization Caveats......................................................................... 713 Pop-Ups .............................................................................................................................714 Portlets ...............................................................................................................................721 Printable Page ...................................................................................................................730 Processing Page................................................................................................................733 Quick Links ........................................................................................................................739 Record History ...................................................................................................................742 Related Links / Shortcuts..................................................................................................748 Rich Content Container.....................................................................................................7518
  • 8. Table of Contents Rich Text Editor .................................................................................................................757 Save Model (Warn About Changes) ................................................................................770 Separator Line ...................................................................................................................775 Search ................................................................................................................................777 Shuttle ................................................................................................................................837 Standard Web Widgets......................................................................................................844 Submitting the Form..........................................................................................................862 SubTab Navigation ............................................................................................................870 Switchers (Application and Context) ...............................................................................878 Tables - Advanced .............................................................................................................882 Tables - Classic .................................................................................................................947 Tabs / Navigation .............................................................................................................1009 Tree...................................................................................................................................1030CHAPTER 5: IMPLEMENTING SERVER-SIDE FEATURES ..............................................................1045 Java Entity Objects .........................................................................................................1045 Create ............................................................................................................................1046 Update / Validate ...........................................................................................................1059 Delete ............................................................................................................................1068 Lock ...............................................................................................................................1072 Rollback .........................................................................................................................1074 Transaction Undo ..........................................................................................................1077 Object Version Number Column.....................................................................................1080 Standard WHO Columns ...............................................................................................1084 Error Handling................................................................................................................1084 9
  • 9. Oracle Application Framework Developers Guide Entity Experts, Validation Applications Modules and Validation View Objects ................1084 Calling PL/SQL Functions and Procedures ....................................................................1087 Entity Objects for Translatable (_TL) Tables ..................................................................1089 Standard Validation Patterns and Examples ..................................................................1091 PL/SQL Entity Object Design and Development ...........................................................1097 Create ............................................................................................................................1098 Insert .............................................................................................................................1100 Lock ...............................................................................................................................1102 Update / Validate ...........................................................................................................1105 Delete ............................................................................................................................1107 Rollback .........................................................................................................................1110 WHO Column Support ...................................................................................................1110 Error Handling................................................................................................................1110 PL/SQL Entity Objects for _TL Tables ...........................................................................1111 Business Service Objects ...............................................................................................1112 Business Service Objects Architecture...........................................................................1112 Business Service Objects in Detail.................................................................................1121 Developing Services ......................................................................................................1134 Methods in Detail ..........................................................................................................1176 Testing Services ............................................................................................................1191 Deploying Services ........................................................................................................1206 Using Services ...............................................................................................................1207 Service FAQ ..................................................................................................................1227 Oracle Application Web Services ...................................................................................122910
  • 10. Table of Contents RESTful Service Interface ...............................................................................................1233 View Objects in Detail .....................................................................................................1246 Application Modules in Detail .........................................................................................1273 Entity Object and View Object Attribute Setters ...........................................................1281CHAPTER 6: ADVANCED OA FRAMEWORK DEVELOPMENT TOPICS ............................................1291 Supporting the Browser Back Button ............................................................................1291 Browser Back Button Support Use Cases .....................................................................1316 OA Framework State Persistence Model (Passivation) ................................................1372 Advanced Java Entity Object Development Topics ......................................................1403 Controlling UIX Rendering Output .................................................................................1417 OA Framework and AOL/J Caching ...............................................................................1421 Application Module and Connection Pooling ................................................................1422 Advanced View Object Development Topics .................................................................1440 JTT/OA Framework Interoperability ...............................................................................1463 Cross-Site Scripting ........................................................................................................1470 Accelerated Validation ....................................................................................................1473CHAPTER 7: TESTING AND DEBUGGING ...................................................................................1489 Discovering Page, Technology Stack and Session Information ..................................1489 Inspecting the MDS Repository Content........................................................................1500 Debugging OA Framework Applications .......................................................................1509 JDeveloper Debugging ..................................................................................................1509 Remote Debugging w/ Apache Installation.....................................................................1511 Remote Debugging w/ Quik Apache ..............................................................................1513 Examining Page Content ...............................................................................................1513 11
  • 11. Oracle Application Framework Developers Guide Examining the Validation Failure Message Log Output ..................................................1514 Logging ............................................................................................................................1517 Testing .............................................................................................................................1523 Running in Test Modes .................................................................................................1523 Using the Business Component Browser (BC4J Tester) ................................................1533 Verifying HTML Page Size .............................................................................................1534 Verifying SQL Performance (Enabling a Database Trace) .............................................1535 Monitoring the Application Monitor / JDBC Connection Pools ........................................1536 Running Oracle Accessibility Checker (OAC).................................................................1536CHAPTER 8: STANDARDS AND GUIDELINES ..............................................................................1537 Oracle E-Business Suite Java Coding Standards .........................................................1537 OA Framework File Standards (Naming, Package Structure and Standard Content).1544 OA Framework Model Coding Standards ......................................................................1570 OA Framework View Coding Standards.........................................................................1594 OA Framework Controller Coding Standards ................................................................1608CHAPTER 9: EXTENDING AND DEPLOYING OA FRAMEWORK APPLICATIONS ..............................1621 Extending OA Framework Applications .........................................................................1621 Deploying Customer Extensions ....................................................................................1632 Deploying Personalizations ............................................................................................1640CHAPTER 10: INTEGRATING WITH OTHER PRODUCTS ...............................................................1655 Portlets ...............................................................................................................................721 Integrating with Oracle ADF............................................................................................1655 Embedding OBIEE Analytics in an OA Framework Page .............................................1656 BI Publisher Integration - Printing A Report From Within an OA Framework Page ......30512
  • 12. Table of Contents JTT/OA Framework Interoperability ...............................................................................1463 Forms / OA Framework Page Integration.........................................................................508APPENDICES ..........................................................................................................................1657 Summary of OA Component Properties ........................................................................1657 Oracle Application Framework Profile Options .............................................................1658 OA Framework ToolBox Technical Reference Manual (TRM) ......................................1688 OA Framework Development Frequently Asked Questions (FAQ) ..............................1698 OA Framework Known Key Issues Release 12..............................................................1699 Oracle Application Framework Troubleshooting ..........................................................1708 Oracle Application Framework URL Parameters...........................................................1709 Oracle Application Framework Extensible Regions......................................................1715 Oracle Application Framework: JDeveloper 9.0.3 IDE vs JDeveloper 10.1.3 IDE ........1716 Sample Code....................................................................................................................1725GLOSSARY .............................................................................................................................1731 13
  • 13. 15
  • 14. Oracle Application Framework Developers Guide16
  • 15. Oracle Application Framework Developers Guide, Release 12.1.3Oracle Application Framework DevelopersGuide, Release 12.1.3PrefaceThis manual describes how to set up your development environment, build, test and deployOracle E-Business Suite OA Framework applications. It also includes the coding standardsfollowed by the Oracle E-Business Suite development staff, instructions for creating pages thatcomply with the Oracle Browser Look and Feel (BLAF) UI Guidelines, and information onextending the products shipped by Oracle E-Business Suite development.Note: Some of the screenshots used in this Guide were captured using Release 11.5.10 whichdisplayed the BLAF Look-and-Feel. Although the colors and interface elements of these imageshave the 11.5.10 appearance, the functionality that they illustrate also applies for Release 12(and the Oracle Look-and-Feel).Contents Audience Related Publications Typographic Conventions Send Us Your CommentsAudienceThis documentation is written for the application developer and assumes familiarity with Javaand SQL.Related PublicationsAdditional Oracle JDeveloper 10g helpsets that apply to OA Framework applicationdevelopment include: OA Framework ToolBox Tutorial OA Component Reference Getting Started with the OA Extension Getting Started with JDeveloper Developing Business ComponentsAs an application designer, you should also be familiar with the Oracle Browser Look and Feel(BLAF) UI Guidelines and the documentation for the Oracle 10g Database.For a full list of documentation resources for the Oracle E-Business Suite Release 12, seeOracle E-Business Suite Documentation Resources, Release 12, OracleMetaLink Document394692.1. 17
  • 16. Oracle Application Framework Developers GuideTypographic ConventionsThis manual uses the following typographic conventions to distinguish important elements fromthe body of the manual.Command and Example SyntaxCommands and examples appear in a monotype font, as follows:Syntax:OAPageContext.getParameter("");Example:/*** Creates a SupplierEOImpl entity object and a corresponding row inthe SuppliersVO.*/public void createSupplier(){ OAViewObject vo = getSuppliersVO(); vo.insertRow(vo.createRow());}Command and example syntax adhere to the following conventions:Convention Explanationplain monotype Used for code fragments and examples.< Italic monotype in Indicates developer-supplied values.angle brackets >... An ellipsis indicates that the actual code extends beyond the example shown./* A C-style comment.*//** A Javadoc comment.*/// A Java comment.Indentation Oracle standard indentation helps to show code structure.Send Us Your Comments18
  • 17. Oracle Application Framework Developers Guide, Release 12.1.3Oracle Corporation welcomes your comments and suggestions on the quality and usefulness ofthis manual. Your input is an important part of the information used for revisions. Did you find any errors? Is the information clearly presented? Do you need more information? If so, where? Are the examples correct? Do you need more examples? What features did you like most?If you find any errors or have any other suggestions for improvement, please indicate thedocument title, and the chapter, section, and page number (if available). You can sendcomments to us in the following ways: Electronic mail: [email protected] FAX: (650) 506-7200 Attn: Oracle E-Business Suite Documentation Manager Postal service: Oracle Corporation Oracle E-Business Suite Documentation Manager 500 Oracle Parkway Redwood Shores, CA 94065 USAIf you would like a reply, please give your name, address, telephone number, and (optionally)electronic mail address.If you have problems with the software, please contact your local Oracle Support Services. 19
  • 18. Oracle Application Framework Developers GuideOracle Application Framework SupportGuidelines for CustomersOverviewThe Oracle Application Framework Developers Guide documents the extensive set of featuresand capabilities made available by the Oracle Application Framework. The information includedin this book is intended to provide our customers with a complete understanding of thetechnology, tools, and standards upon which OA Framework based applications in the E-Business Suite are built.With Release 12, we now provide customers with tools to perform certain types ofcustomizations to OA Framework based applications that were not available with prior releases.In reviewing the capabilities and methods presented in this document, it is very important thatyou take into consideration that the type of resources available to support your work, dependupon the extent and type of customization that you are planning to perform.This document is intended to provide guidelines to customers regarding what support optionswill be available, primarily for customizations with OA Framework Release 12. We expect thatthis document will be updated with additional information and details on an ongoing basis. Themost current version of this document is published in My Oracle Support Note 395441.1. Beforestarting any customization work, it is essential that you review the latest version of thisdocument.Contents Understanding the Support Options Available Important Limitations and GuidelinesUnderstanding the Available Support OptionsRelease 12 of the Oracle Application Framework (OA Framework) provides significant newcapabilities to perform personalizations, and extend OA Framework based web applications, ina variety of ways. For a full description of available options, please refer to the CustomizationPrimer in the Oracle Applications Framework Personalization Guide. In this note, the use of theterm customizations collectively refers to those capabilities.The objective of this note is to assist Oracle E-Business Suite customers with understanding thelevel of support provided for the different types of customizations possible, including alternativeresources that are available for certain types of work, which fall beyond the scope of standardsupport processes that customers may already be familiar with.PersonalizationsPersonalizations performed within the scope of the OA Personalization Framework are a fullysupported means of customizing OA Framework based applications.20
  • 19. Oracle Application Framework Developers Guide, Release 12.1.3Due to its declarative nature and durable architecture, the OA Personalization Frameworkcontinues to be recommended as the primary means for customizing OA Framework basedapplications. The supported capabilities, methods and tools for performing personalizations aredocumented in the Oracle Application Framework Personalization Guide. The most currentversion of this Personalization guide is published in the Oracle E-Business Suite DocumentationLibrary, which is supplied on a physical CD in the Oracle E-Business Suite Release 12 softwarebundle. This document may also be obtained in hard copy format from the Oracle Store.Access the latest content from the Oracle E-Business Suite Online Documentation CD.Methods or capabilities that not detailed in the Oracle Application Framework PersonalizationGuide, fall beyond the scope of the OA Personalization Framework, and are not supported forOracle E-Business Suite installations.Customers leveraging the capabilities of the OA Personalization Framework must ensure theirRelease 12 instance is kept current with the latest OA Framework patchset applied. Whenreporting issues against Personalization, Oracle Support will as a first step, require you to checkand confirm you have applied the most current patchset to ensure that the latest fixes for knownissues have been applied to your instance. You can find more information about the currentpatchset, if available, including known issues addressed in that patchset by referring to theOracle Application Framework Documentation Resources, Release 12 (Metalink Note391554.1).ExtensionsRelease 12 of the OA Framework and the accompanying Oracle 10g JDeveloper releaseprovide features for developing a new class of Oracle applications extensions not available tocustomers in prior releases.Assistance with customer-developed extensions is available via the following resources: Oracle Application Framework Developers Guide The Developers Guide fully documents the capabilities of the Framework including instructions, examples and essential standards for implementing business-tier objects, UI components and server-side features. Specifically, Chapter 9 of the Developers Guide under the section Extending OA Framework Applications, provides instructions on how to extend OA Framework based applications with custom business logic, including detailed guidelines for BC4J code extensions. Oracle Application Framework ToolBox Tutorial Application The ToolBox Tutorial application is a sample application accompanied by extensive examples with step-by-step instructions that demonstrate the usage of business objects and UI components to build OA Framework based application pages, against a simple Purchase Order type application schema, installed on your Release 12 instance. The ToolBox includes a specific tutorial lab on Extending OA Framework Applications. OA Framework Javadoc Documents all core Oracle Application Framework packages and classes, including UIX and BC4J objects extended by the Framework. OA Framework Discussion Forum on the Oracle Technology Network OTN (http://otn.oracle.com) hosts a discussion forum for OA Framework Extensions and the OA Extension to Oracle JDeveloper 10g. Navigate to OTN Forums 21
  • 20. Oracle Application Framework Developers Guide under the E-Business Suite (http://forums.oracle.com/forums/index.jsp?cat=3). You can use the forum to post questions and exchange information with other customers on the OTN community working on extensions. The OA Framework Development team and Oracle Support will monitor and participate in some of the discussion threads on this forum. Additionally, you may also consider participating in the OTN JDeveloper forum for usage questions concerning Oracle JDeveloper 10g. Oracle E-Business Suite Product Documentation Some products may provide additional information on extending application specific business objects and functionality. Consult My Oracle Support (http://support.oracle.com) under the respective product for more information.For issues logged with Oracle Support to address questions concerning OA Framework basedextensions or usage of the OA Extension tool, Oracle Support will evaluate the nature of thequestion, and in most cases refer the customer to one or more of the resources outlined above.Important Limitations and GuidelinesBefore starting work on any customizations, it is essential that customers be aware of thefollowing limitations and guidelines: Customers who intend to work with Oracle JDeveloper 10g OA Extension, and develop extensions to their installed OA Framework-based self-service applications must use the specific build of the Oracle JDeveloper 10g that corresponds to the OA Framework Release 12 installed in their runtime environment. Please consult the corresponding "About Oracle E-Business Suite Technology Update" document for the JDeveloper ARU that corresponds to the Release 12 ATG patchset you install. Oracle does not provide access to Java source code for OA Framework or products. You should consider the Developers guide and available Javadoc for the classes you are working with as the only documented sources of information available to determine the characteristics of the object you are extending. Design-time options and expected run-time behavior of OA Framework components are fully documented in the Developers Guide and Javadoc mentioned above. In order to log issues with Oracle Support concerning components, such as unexpected run-time behavior of a component, customers will be required to provide a simple reproducible test case written against the OA Framework ToolBox Tutorial schema or an E-Business Suite product schema. The test case must not rely on any custom schema elements or custom class libraries, and must be runnable by Oracle Support without any custom dependencies. Oracle does not recommend that customers extend controller objects associated with regions or web beans in shipped E-Business Suite product pages. Controller class (oracle.apps.fnd.framework.webui.OAControllerImpl) methods should effectively be considered private, since their implementation is subject to change. Controller extensions are therefore not considered to be durable between upgrades. If it is absolutely essential to handle custom form submit events on a shipped product page,22
  • 21. Oracle Application Framework Developers Guide, Release 12.1.3 processFormRequest() is the only method that should be overriden in a controller class, although the risks outlined above still apply. Customers are fully responsible for all custom code written to support customer- developed extensions. Oracle Support and E-Business Suite development will not review custom code. Questions such as those relating to design, and usage of components to develop extensions, will generally be redirected to the OTN forums mentioned above. To facilitate transparent upgrades and new feature uptake, custom code must comply with the Oracle E-Business Suite OA Framework coding standards described in Chapter 8 of the OA Framework Developers Guide. Note: Information about the forthcoming passivation feature is provided throughout the Developers Guide (including the coding standards) for preview/planning purposes only; passivation is not supported in Release 12. Customers planning to undertake advanced or complex extension projects may consider engaging services available from Oracle Consulting or Oracle Partner resources. Oracle Consulting and Partner organizations offer an alternative means of support through consulting resources who have been specially trained or certified on OA Framework and Oracle E-Business Suite technology. For more information on what options are available, please refer to the information under Oracle Consulting Services (http://www.oracle.com/consulting) and the Oracle Partner Network (http://www.oracle.com/webapps/opus/pages/SimpleSearch.jsp). 23
  • 22. Oracle Application Framework Developers Guide24
  • 23. Oracle Application Framework Developers Guide, Release 12.1.3Chapter 1: Getting StartedIntroduction to OA FrameworkThis document provides an overview of OA Framework and discusses: Architecture Key features SummaryOverviewOracle Application Framework (OA Framework) is the Oracle E-Business Suite developmentand deployment platform for HTML-based business applications. OA Framework consists of aset of middle-tier runtime services and a design-time extension to Oracle JDeveloper calledOracle E-Business Suite Extension (OA Extension).During the first few years after the Internet evolution, the software industry witnessed an influxof rapidly changing technologies. These technologies matured, yet there are still a myriad oflow-level and complex technologies that are hard to learn and implement. Under thesecircumstances, OA Framework has emerged as an integrated platform for developing anddeploying Oracle E-Business Suite HTML-based applications, leveraging technologicaladvances without taking on associated complexity. Since its inception, OA Frameworkembraces the following principles:End User ProductivityThe shift from client-server to multi-tier deployments comes with many cost savings, but notwithout compromise. HTML-based applications started out very much like old mainframeterminals; actions on the client side resulted in a round trip to the middle tier.Over time, user interface interactivity improved. OA Framework has always kept user interfaceinteractivity a top priority with features such as partial page rendering (PPR), hot keys, smartchoice lists and auto-completion of fields with lists of values. In addition, Oracle focuses awealth of resources and expertise on user behavior and psychology, to develop a set of userinterface layout and interaction standards, commonly known as the BLAF (Browser-Look-And-Feel) guidelines. BLAF is the default look and feel that all OA Framework applications assume,but can be personalized in many ways to meet customer branding and style requirements. OAFrameworks implementation of BLAF standards yields a consistent user experience and furtherenhances user productivity.Enterprise-Grade Performance and ScalabilityOA Framework has aggressive performance and scalability targets. Most Oracle E-BusinessSuite application pages have sub-second response times to most user interactions. It takes a bitlonger the first time a page is accessed within the same Java Virtual Machine, but thereafter,most of the commonly needed information (such as user information) is cached in the middle 25
  • 24. Oracle Application Framework Developers Guidetier, allowing faster response. Resources are conserved through a number of resource poolingmechanisms and the swapping of idle resource data between memory and database.Developer ProductivityOA Framework is designed around the simple Model-View-Controller (MVC) architecture. Toshield application developers from costs associated with the rapidly changing technologicallandscape, Oracle has adopted a declarative flavor of the MVC architecture. Key building blocksof an application are defined in a descriptive manner using a simple JDeveloper user interfaceand then saved in an industry standard XML format. Oracle extends access and benefits of theOA Framework development environment to all Oracle E-Business Suite customers andpartners. Customers and partners can leverage the proven OA Framework technology to addextensions to their Oracle E-Business Suite applications.Application CustomizabilityOracle is able to exploit its twenty plus years of experience in building and deploying businessapplications, to architect OA Framework with durable and economical customizations. Oraclehas kept that goal in focus and produced a very compelling solution with plenty of flexibility totailor the user interface (look-and-feel) and business logic. Thanks to the declarative and objectoriented nature of OA Framework, application personalization and extensibility is readilyavailable at a fraction of the industry startup cost and at a very minimal maintenance cost, ifany.Open StandardsOracle continues to be a champion of industry standards and an active participant in thedevelopment of several emerging standards. OA Framework technologies have driven severalindustry standards and have adopted several others as they were published. Several Oracletechnology architects are active members on a number of standards drafting committees. OAFramework is J2EE based and features several industry standards such as XML, HTML, Java,JSP, SQL and Web Services.ArchitectureOA Framework is based on the industry-standard J2EE MVC design pattern. Developersmanipulate the applications metadata using Oracle JDeveloper OA Extension, while OAFramework uses the most efficient manner to execute the application. The MVC architecture isa component-based design pattern with clean interfaces between the Model, View, andController. The Model is where the application implements its business logic. The View is wherethe application implements its user interface and the Controller is where the application handlesuser interaction and directs business flow.Figure 1: OA Framework MVC architecture.26
  • 25. Oracle Application Framework Developers Guide, Release 12.1.3OA Extension offers the following design time tools: UML tools to model and generate business logic. Guided user interface (and visual editors in a future release) to lay out client user interfaces. Code generation for Controller classes.The OA Framework Model is implemented using Oracle Business Components for Java (BC4J).BC4J provides optimized, ready-to-use implementations of the J2EE design patterns thatdevelopers otherwise would have to code, debug, and test by hand. By leveraging BC4Jscombination of tested code and productivity tools inside the Oracle JDeveloper IDE,development teams can focus immediately and only, on writing business logic and userinterfaces instead of on designing, coding, and debugging handcrafted application "plumbing"code.OA Framework View is implemented using UI XML (UIX). UIX uses XML to describe thecomponents and hierarchy that make up an application page. UIX also provides runtime 27
  • 26. Oracle Application Framework Developers Guidecapabilities to translate that metadata into HTML output so that it can be shown on a Browser ora 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 OA Controller, which is a pure Java class implementation, handles user and application-driven interactions. Simple page flows (such as a 2-step transaction) are implemented directlyinto the Controller object; others are implemented using Oracle Workflow. In a future release,business flows will be implemented in a declarative manner similar to that used to define modeland view objects.Key FeaturesThis section the following key features of OA Framework: Integrated development environment Durable personalizations and extensions Consistent and compelling user interface User interface interactivity Object oriented reuse Oracle portal interoperability Built-in security Deployment environmentIntegrated Development EnvironmentOracle JDeveloper with OA Extension (OA Extension) is a world-class J2EE-based integrateddevelopment environment. Oracle customers and third party consultants have access to thesame tools used by Oracle E-Business Suite developers to build complementary applications aswell as extend the Oracle E-Business Suite applications. OA Extension provides features suchas easy-to-use wizards, a hierarchy navigator, and a property sheet. These features enabledevelopers to populate the metadata for declarative application business logic and userinterfaces. JDeveloper offers a wealth of productivity tools such as the UML modeler, codecoach, integrated debugger, local testing environment and documentation generator.With the OA Extension software comes a wealth of documentation and learning aids including aDevelopers Guide, Javadoc, Online Help, a Sample Library and a rich set of Tutorials.Durable Personalizations and ExtensionsPersonalization is about declaratively tailoring the UI look-and-feel, layout or visibility of pagecontent to suit a business need or a user preference. Examples of personalization include: Tailoring the color scheme of the UI. Tailoring the order in which table columns are displayed. Tailoring a query resultExtensibility is about extending the functionality of an application beyond what can be donethrough personalization. Examples of extensibility include:28
  • 27. Oracle Application Framework Developers Guide, Release 12.1.3 Adding new functional flows. Extending or overriding existing functional flows. Extending or overriding existing business logic.OA Framework is designed with durable personalization and extensibility capabilities, achievedthrough the declarative architecture and the underlying object oriented implementation.Declarative UI component definitions are stored in the form of metadata in a databaserepository. Personalizations are translated into offsets from the base metadata definition andstored separately. At runtime, all applicable personalization metadata is loaded from therepository and layered over the base metadata definition to produce the net effect. Productupgrades and patching only affect the base metadata definition so that customerpersonalizations are preserved and continue to function properly.Personalizations can be implemented at several levels by one of three authors: applicationdeveloper, application administrator and end user.An end-user can create a personalization to be applied to specific user interface componentsthat is only visible in the context of that authoring user. For example, an end user may save anemployee search result sorted by manager and hide the employees date of birth column. Oncethis personalized view is saved under a given name, the user can retrieve that view again in thefuture by that name.Application administrators and application developers have the flexibility to tailor the userexperience at several levels. They can author personalizations that affect all users, users of aparticular locale, users of a particular organization, users with a particular role and in the contextof a particular function. Several levels can apply at the same time with a predeterminedprecedence order that yields a very personalized user experience.Using a combination of OA Extension wizards and built-in personalization screens, several userinterface and business logic extensions are made possible at a minimal cost to developmentwith little-to-no maintenance cost. In addition, Oracle E-Business Suite customers continue toenjoy the extensibility features offered by Oracle Flexfields, Oracle Workflow and BusinessEvents.Consistent and Compelling User InterfaceOA Framework offers developers a wide range of user interface components that make thebuilding of applications into a more assembly process, freeing developers from the repetitivecomposition of common user interface constructs. Moreover, OA Frameworks declarativeapproach to building application user interfaces frees developers from the need to learn a vastarray of changing technologies, while offering end users a consistent application look andexperience. OA Framework user interface components range from simple widgets such asbuttons and fields to compound components such as tables-in-tables and hierarchical grids.User Interface InteractivityOA Framework is always exploring the technology frontiers to enrich the interactivity of HTML-based user interfaces. Along those lines, OA Framework provides several features: 29
  • 28. Oracle Application Framework Developers GuidePartial Page Rendering (PPR)PPR is a means by which designated parts of a page, rather than the whole page, is refreshedwhen the user performs certain actions. OA Framework supports PPR on actions such as: tablerecord-set navigation, table sorting, table column totaling, adding a row to a table, row-level andcell-level detail disclosure, toggling the visibility of a Hide/Show component, populating a LOV,subtab navigation, Gantt chart refreshing and descriptive Flexfields context switching. Moreover,developers can declaratively enable PPR events on several components. For example, adeveloper can: Configure the selection of a poplist to cause related fields to render, be updatable, be required or be disabled based on the selected value. Configure the value change of a text field to set related field values (for example, if you set a Supplier value and tab to the next field, the dependent Supplier Site defaults automatically). Configure the selection of a master tables record to automatically query and display related rows in a detail table.Accelerator (Hot) KeysOA Framework supports mnemonic accelerator keys for selected buttons and enablesdevelopers to assign numeric access keys to product specific user actions.Enhanced Save ModelOA Framework provides a default implementation to warn users when they are about to losechanges such as when they click on a link that takes them outside the context of the currenttransaction. Developers can override the default behavior on a component-by-component basis.Smart PoplistOA Framework supports a personalizable hybrid between a static poplist and a searchable listof values. The poplist includes the most popular values a user uses to populate a particularattribute. The user can personalize the values that show up in the poplist by picking new valuesfrom a list of values. Moreover, the user can personalize the order in which values are listed inthe poplist as well as remove less popular values. This feature is also referred to as a LOVChoicelist.LOV Auto CompletionLists of values (LOVs) are used when the list of possible values is long and the user may wantto conduct a search before picking a value. In some business scenarios, especially with clericaljobs, the user uses a small set of values or may find it faster to type a partial value. If the userenters a partial value in a field that is associated with an LOV, OA Framework conducts asearch before bringing up the LOV window. If the search leads to a unique record, OAFramework completes the rest of value for the unique record and saves the user from having touse the LOV window.Object Oriented Reuse30
  • 29. Oracle Application Framework Developers Guide, Release 12.1.3OA Framework applications can be abstracted into a series of concentric layers, like an onion.The core layer represents the database and the surface layer represents the application pages.In between is a number of business logic and user interface layers. This layering allows forgeneric code and components to be implemented at the inner layers to maximize their reuseacross the outer layers. For example, attribute validation is implemented at the Entity Object (aBC4J object-oriented representation of a database table in the middle tier) level. All applicationpages that provide the user with the ability to populate or update the value of the subjectattribute would receive attribute validation for free through the underlying entity object. On theuser-interface side, reusable components can be saved as shared regions in the metadataservices (MDS) repository and reused across several pages. An administrator can choose topersonalize the shared region such that the personalization impacts all instances of the sameregion across pages or personalize the shared region only in the context of the current page.Oracle Portal InteroperabilityOA Framework offers developers a simple approach to publishing OA Framework components(commonly known as regions) as Oracle Portal-compatible portlets. Oracle Portal provides youwith a common, integrated starting point for accessing all your data. Since Oracle Portal lets youpersonalize the content and look of your page, you can also personalize the application regionthat is displayed as a portlet. Any personalizations you make to that portlet region appear onlywhen you display that region from the same portlet.Built-in SecurityHTML-based applications offer great user and administrator convenience, but special care mustbe taken to ensure that these applications are secure. Developing HTML applications that aretruly unbreakable is very difficult, historically requiring application developers to also be securityexperts. In fact, most application developers are not security experts, and they should not need 31
  • 30. Oracle Application Framework Developers Guideto be. It is the responsibility of the application framework to ensure that HTML transactions areauthorized, private, and free from tampering. OA Framework provides built in protection againstknown HTML hacking strategies, leaving the application developer free to concentrate onapplication functionality. Also, since UI components are defined in metadata rather than in code,the security protection offered by OA Framework can be advanced to keep up with the state ofthe art, without requiring applications to be rewritten.Deployment EnvironmentOA Framework applications are deployed using standard Oracle 10g AS / Apache andOracle10g Database servers. Application pages can be rendered on Internet Explorer 5.0 orabove, Netscape 4.73 or above and Mozilla 1.5 or above. The data and middle tiers can bedeployed on several platforms including Linux, UNIX and Windows.SummaryBased on the Model-View-Controller (MVC) architecture, OA Framework lets applicationdevelopers focus on the business requirements rather than on the underlying technologies. Byusing declarative and guided-coding (and soon visual) techniques, OA Framework allowsapplication developers who are not necessarily J2EE experts to quickly become productive. OAFramework-based applications offer a highly consistent user experience with the highest levelsof user interactivity without a client footprint. Applications are optimized for sub-secondresponse to most user interactions and competitive scalability trends. OA Framework exploits itsdeclarative and object-oriented architecture to offer the most durable personalization andextensibility capabilities on the market, at a fraction of the cost. OA Framework featurestranslate to lower costs of ownership, better user experience and competitive deployments.32
  • 31. Oracle Application Framework Developers Guide, Release 12.1.3Setting Up Your Development EnvironmentThis document describes how to configure and test an OA Framework Release 12 developmentenvironment for the following use cases: Customer, Consultant or Support Representative Using JDeveloper on Windows. Customer, Consultant or Support Representative Using JDeveloper on Linux.Note: Oracle employees who have installed Oracle JDeveloper OA Extension and want to setup and test this environment should select the Customer link.Customer, Consultant or Support Representative UsingJDeveloper on WindowsThis section contains instructions to configure and test OA Framework if you are a customer,consultant or support representative using JDeveloper on Windows. It provides an overview ofthe directory structure and discusses how to: Configure the JDEV_USER_HOME environment variable. Obtain a database connection file. Create a desktop shortcut to JDeveloper. Assign Toolbox responsibilities. Launch JDeveloper and configure the database connection and user. Test the setup.OverviewThese instructions assume you have successfully installed the JDeveloper OA Extension zip filewhich creates the following directory structure on your drive of choice.Directory DescriptionTip: To open any of the documentation in the jdevdoc directories, open thejdevdocindex.htm.jdevdocjavadocfwk Includes OA Framework Javadoc.jdevdocjavadocaolj Includes AOL/J Javadoc.jdevdocjavadocbc4j Includes BC4J Javadoc.jdevdocjavadocuix Includes UIX Javadoc.jdevdoctoolbox Includes OA Framework ToolBox Tutorial lesson/lab documentation.jdevdocdevguide Includes the OA Framework Developers Guide.jdevbin Includes an extended version of the Oracle JDeveloper 10g executable and OA Framework class libraries.jdevhome Includes the OA Framework ToolBox Tutorial source and developer working area. 33
  • 32. Oracle Application Framework Developers GuideTask 1: Configuring the JDEV_USER_HOME Environment VariableWarning: This is a requirement for JDeveloper. Do not skip this task.Configure the JDEV_USER_HOME environment variable using Windows XP or Windows2000: 1. Go to your desktop and select My Computer, right-click and select Properties. 2. On the System Properties dialog, select the Advanced tab. 3. On the Advanced page, select the Environment Variables... button. 4. On the Environment Variables dialog, select the New... button from the User variables for box. 5. On the New User Variable dialog, enter JDEV_USER_HOME in the Variable Name field. Set the Variable Value field to :jdevhomejdev where is the drive where you installed the JDeveloper OA Extension zip file. For example: c:jdevhomejdev. 6. Select OK in each of the dialogs you opened to save the new user environment variable.Warning: The variable value should not contain a leading space before the drive name. If itdoes, your environment will not work properly.Task 2: Obtaining a Database Connection FileObtain the FND database connection (.dbc) file from the system administrator who installed theOA Framework database where you want to do your development. Place this file in thedbc_filessecure directory.Task 3: Creating a Desktop Shortcut to JDeveloperTo facilitate launching JDeveloper, create a desktop shortcut tojdevbinjdevbinjdevw.exe.Task 4: Assigning ToolBox ResponsibilitiesIf you have not already done so as part of your installation verification, assign the followingToolBox Tutorial responsibilities to a test user. Refer to the Oracle E-Business Suite SystemAdministrators Guide for information about creating users and assigning responsibilities tousers.Note: Use an existing user in your system or create a new test user. OA Framework ToolBox Tutorial (responsibility key is FWK_TBX_TUTORIAL). OA Framework ToolBox Tutorial Labs (responsibility key is FWK_TOOLBOX_TUTORIAL_LABS).Task 5: Launching JDeveloper and Configuring the Database Connectionand User34
  • 33. Oracle Application Framework Developers Guide, Release 12.1.3Use this procedure to launch JDeveloper and configure the database connection and user: 1. Select the desktop shortcut created in Task 3 to launch Oracle JDeveloper. 2. Select File > Open from the main menu, then navigate to myprojects. Open the OA Framework ToolBox Tutorial workspace file (toolbox.jws). 3. Expand the toolbox.jws in the JDeveloper System Navigator, to display its contents. Select the Tutorial.jpr project, then select Project > Project Settings. 4. Expand the Oracle Applications node, which is In the Project Settings dialog, and select Runtime Connection. 5. Locate the DBC file that you saved in Task 2 by using the Browse... button, which is In the Connection box. The file should be in the dbc_filessecure directory. 6. Specify the User Name and Password for the test user. This is the user that you assigned the ToolBox responsibilities to in Task 4. Select OK. 7. Repeat Steps 3 - 6 for the LabSolutions.jpr project. 8. Expand the Connections node in the JDeveloper System Navigator and then expand the Database node. Right-click on the Database node and select New Connection... to open the Connection Wizard. Follow the JDeveloper instructions to define a new database connection for the Oracle E-Business Suite database identified by the DBC file you selected above. 9. Select the Tutorial.jpr project In the System Navigator. Right-click and select Edit Business Components Project.... 10. Select the Connection option in the Business Components Project Wizard and set the Connection Name to the connection you just defined. Select OK to save your changes. 11. Repeat steps 8 - 10 for the LabSolutions.jpr project.Task 6: Configuring the Environment Encoding of JDeveloper Confirm the environment encoding of your JDeveloper if it is appropriately set. To see the environment encoding, see your preferences of JDeveloper. If Encoding is not set to "UTF-8", set it to "UTF-8".Task 7: Test your SetupPerform the following steps to test your setup:Tip: If you want pages to look as they do in the OA Framework ToolBox Tutorial / SampleLibrar, use Internet Explorer 5.0+ as your default browser. 1. Open the toolbox.jws workspace in the JDeveloper Navigator using the instructions in Task 5 above. 2. Go to the System Navigator, select toolbox.jws and then select Project > Rebuild toolbox.jws from the main menu. You should get 0 errors (warnings are okay and expected). 3. Go to the System Navigator, expand the Tutorial.jpr project again, then select Project > Show Categories from the main menu. 35
  • 34. Oracle Application Framework Developers Guide Note: this helps to organize the files in a large project. 4. Expand the HTML Sources category beneath Tutorial.jpr. Select test_fwktutorial.jsp, then select Run > Run test_fwktutorial.jsp from the main menu. Perform the following: o Select Hello, World! from the list of lesson links displayed on the Test Framework ToolBox Tutorial page. This runs a very simple page. Note: If you cant run the Hello, World! page; revisit the steps listed above to ensure that you completed everything correctly. If the problem persists, follow the support procedure described in the Release Notes accompanying this ARU.You are now ready for hands-on experience with the Oracle JDeveloper OA Extension. TheToolBox Tutorial lessons can be launched from jdevdocindex.htmCustomer, Consultant or Support Representative UsingJDeveloper on LinuxThis section contains instructions to configure and test OA Framework if you are a customer,consultant or support representative using JDeveloper on Linux. It provides an overview of thedirectory structure and discusses how to: Configure the JDEV_USER_HOME and JDEV_JAVA_HOME environment variables. Obtain a database connection file. Assign Toolbox responsibilities. Launch JDeveloper on Linux. Configure the database connection and user. Test the setup.OverviewThese instructions assume you have successfully installed the JDeveloper OA Extension zip filewhich creates the following directory structure on your drive of choice.Directory DescriptionTip: To open any of the documentation in the jdevdoc directories, open thejdevdocindex.htm.jdevdocjavadocfwk Includes OA Framework Javadoc.jdevdocjavadocaolj Includes AOL/J Javadoc.jdevdocjavadocbc4j Includes BC4J Javadoc.jdevdocjavadocuix Includes UIX Javadoc.jdevdoctoolbox Includes OA Framework ToolBox Tutorial lesson/lab documentation.jdevdocdevguide Includes the OA Framework Developers Guide.jdevbin Includes an extended version of the Oracle JDeveloper 10g36
  • 35. Oracle Application Framework Developers Guide, Release 12.1.3 executable and OA Framework class libraries.jdevhome Includes the OA Framework ToolBox Tutorial source and developer working area.Task 1: Configuring the JDEV_USER_HOME and JDEV_JAVA_HOMEEnvironment VariablesAttention: These commands must be executed from the bourne shell. 1. Assign a value to the JDEV_USER_HOME variable. For example: JDEV_USER_HOME=/home//jdevhome/jdev 2. Assign a value to the JDEV_JAVA_HOME variable. Example - OS Red Hat version 2.1: JDEV_JAVA_HOME=/jdevbin/linux/j2sdk1.4.2_03 Example - OS Red Hat version 3.0: JDEV_JAVA_HOME=/jdevbin/linux/j2sdk1.4.2_04 unset LD_ASSUME_KERNEL Note: Both Red Hat versions, (2.1 and 3.0); have been tested successfully by Oracle JDeveloper OA Extension. 3. Export the two variables: export JDEV_USER_HOME export JDEV_JAVA_HOMETask 2: Obtaining a Database Connection FileObtain the FND database connection (.dbc) file from the system administrator who installed theOA Framework database where you want to do your development. Place this file in thedbc_filessecure directory.Task 3: Assigning ToolBox Responsibilities 37
  • 36. Oracle Application Framework Developers GuideIf you have not already done so as part of your installation verification, assign the followingToolBox Tutorial responsibilities to a test user. Refer to the Oracle E-Business Suite SystemAdministrators Guide for information about creating users and assigning responsibilities tousers.Note: Use an existing user in your system or create a new test user. OA Framework ToolBox Tutorial (responsibility key is FWK_TBX_TUTORIAL). OA Framework ToolBox Tutorial Labs (responsibility key is FWK_TOOLBOX_TUTORIAL_LABS).Task 4: Launching JDeveloper on LinuxRun this command from the bourne shell to launch JDeveloper:/jdevbin/jdev/bin/jdev -verboseTask 5: Configuring the Database Connection and UserUse this procedure to configure the database connection and user: 1. Launch JDeveloper and then select File > Open from the main menu. Navigate to myprojects and open the OA Framework ToolBox Tutorial workspace file (toolbox.jws). 2. Expand the toolbox.jws in the JDeveloper System Navigator, to display its contents. Select the Tutorial.jpr project, then select Project > Project Settings. 3. Expand the Oracle Applications node, which is In the Project Settings dialog, and select Runtime Connection. 4. Locate the DBC file that you saved in Task 2 by using the Browse... button, which is In the Connection box. The file should be in the dbc_filessecure directory. 5. Specify the User Name and Password for the test user. This is the user that you assigned the ToolBox responsibilities to in Task 3. Select OK. 6. Repeat Steps 2 - 5 for the LabSolutions.jpr project. 7. Expand the Connections node in the JDeveloper System Navigator and then expand the Database node. Right-click on the Database node and select New Connection... to open the Connection Wizard. Follow the JDeveloper instructions to define a new database connection for the Oracle E-Business Suite database identified by the DBC file you selected above. 8. Select the Tutorial.jpr project In the System Navigator. Right-click and select Edit Business Components Project.... 9. Select the Connection option in the Business Components Project Wizard and set the Connection Name to the connection you just defined. Select OK to save your changes. 10. Repeat steps 7 - 9 for the LabSolutions.jpr project.Task 6: Testing the Setup38
  • 37. Oracle Application Framework Developers Guide, Release 12.1.3Tip: To use Mozilla as your default browser, create a symbolic link. For example, netscape= local/bin/mozilla.To test your setup: 1. Open the OA Framework ToolBox Tutorial workspace file by selecting File > Open from the main menu. Navigate to myprojects and open the file toolbox.jws. 2. Select toolbox.jws and select Project > Rebuild toolbox.jws from the System Navigator main menu. You should get 0 errors (warnings are okay and expected). 3. Expand the Tutorial.jpr project and then select Project > Show Categories from the System Navigator main menu. (This helps to organize the files in a large project). 4. Expand the HTML Sources category beneath Tutorial.jpr. Select test_fwktutorial.jsp, and select Run > Run test_fwktutorial.jsp from the main menu: 5. Select Hello, World! from a list of lesson links displayed on the Test Framework ToolBox Tutorial page, to run a very simple page. Note: If you cant run the Hello, World! page; revisit the steps listed above to ensure that you completed everything correctly. If the problem persists, check the Oracle JDeveloper OA Extension FAQ for troubleshooting tips. If it still doesnt work, send an email to the OA Framework support mail list (see the OA Framework web site for additional information about this). 39
  • 38. Oracle Application Framework Developers GuideBuilding and Running Hello, World!OverviewThis tutorial leads you through using Oracle JDeveloper with OA Extensions to create a verysimple page. This tutorial has minimal explanation, few steps and no BC4J.This tutorial also assumes a basic prior knowledge of working with JDeveloper.You should also have your development environment set up and working. For assistance insetting up your development environement see "Setting Up Your Development Environment"This lab takes approximately 1-3 hours.Hello, World Lab GoalsAfter completing this exercise, you will have learned how to: Create an Oracle Applications (OA) JDeveloper workspace and project. Configure a project to enable Developer Mode testing and diagnostics. Use the JDeveloper OA Extension to create a very simple page. Create a controller and associate it with a region. Handle a submit button press action (an HTTP POST request). Run a page in regular and debug modes.The resulting page has the global links (such as Preferences, Logout, and Return to Portal), aheader, a footer, a Personalize Region link, one empty field and one Go button.The finished "Hello World" page does nothing other than display a message when you enter avalue in the field and click the Go button. Your final page and layout will look like the following:40
  • 39. Oracle Application Framework Developers Guide, Release 12.1.3Note that there are several profile options that control features such as personalization, thevisual appearance of global links, and other features, so what you see may be different from thepicture above. Differences you are most likely to encounter are not seeing the PersonalizeRegion link, seeing button icons above the corresponding global links, or not seeing certainglobal links such as Customize (if personalization is not enabled for your username).Step 1. Create a New OA Workspace and Empty OA Projectwith the New... Dialog.Select File > New... to open the New... dialog (shown in the following diagram). This dialog isalso called the New Object Gallery. 41
  • 40. Oracle Application Framework Developers GuideChoose General > Workspace Configured for Oracle Applications from the New... dialog, orhighlight Workspaces in the Navigator and choose New OA Workspace... from the contextmenu (right mouse button menu that changes depending on the context). Youll be prompted tocreate an OA workspace. Verify that the default workspace directory name points to your ownmyprojects directory, as shown in the following diagram. Modify theworkspace file name as well (any name is okay for a workspace, such asHelloWorldOAWorkspace.jws). Check the Add a New OA Project check box.After you click OK, you will see the Oracle Applications Project Wizard after a Wizard Welcomescreen. You can skip the welcome screen and select Next.42
  • 41. Oracle Application Framework Developers Guide, Release 12.1.3In Step 1 of the wizard, verify that the default project directory name points to your ownJDEV_USER_HOMEmyprojects directory, as shown in the following diagram. Modify theproject file name as well (any name is okay for a project, such asHelloWorldOAProject.jpr). Set the default package name to the following (where "hello" isthe component):oracle.apps.ak.helloNote: For this exercise and for all later lab exercises, you must use the exact package,page, region, item and variable names specified in the instructions, because theinstructions depend on having these names. Specifically, you must use oracle.apps.... inyour package names for the labs even if you are an Oracle E-Business Suite customer orpartner (though you would use .oracle.apps.... in production objectsyou create).In Step 2 of the wizard, verify that the XML Path points to your ownJDEV_USE