POSTS CATEGORIES

Translate

Showing posts with label ADF Concepts. Show all posts
Showing posts with label ADF Concepts. Show all posts

The Goals for ADF Business Components



ADF Business Components (ADFbc) is the framework used in Oracle Fusion Applications for building database-centric business services. It provides a highly declarative way of developing Java objects on top of relational database tables. In addition to providing the core feature of the
Model layer, described earlier, it provides value-added features such as the ability to declare calculated attributes, lists of values, query by example, and predefined filter criteria.

So, if you want to build an application based on the Customers and Orders tables in the database, ADF Business Components allows you to rapidly build a business service based on that data model. It will automatically implement database constraints for any master/detail relationships, and provide methods for manipulating the data model such as commit, rollback, and delete.


There are a number of goals for a business services framework like ADF
Business Components. At the most fundamental level, a business service is required to query information from an underlying database and cache that data while various operations are performed on it. It then has to validate the data changes and complete the transaction by committing the data back to the database. This use case can be broken down into the following
high-level tasks:


  • Defining application objects that map to database tables
  • Managing data and business logic validation
  • Creating application-specific views of the data
  • Coordinating master/detail behavior of the business model based on foreign key relationships
  • Providing default operations such as commit, delete, and update on the data model


ADF Business Components provides these core features within the framework in a generic way, allowing these generic services to be adapted for the application-specific case.

The core features and functionality of the ADF Business Components framework are implemented in Java. For the most part, the Java classes responsible for the previously noted features, and more, are hidden from the Fusion developer. Instead, the developer generates and maintains metadata
through property pages and declarative editors, and it is this metadata that drives the generic Java framework classes when the application runs.

Oracle ADF Architecture


Oracle ADF Architecture is based on the Model-View-Controller (MVC) design pattern.MVC consists of three layers which are model layer,view layer,controller layer.Oracle ADF implements MVC and further separates the model layer from the business services to enable service-oriented development of applications.
  • The model layer represents the data values related to the current page
  • The view layer contains the UI pages used to view or modify that data
  • The controller layer processes user input and determines page navigation
  • The business service layer handles data access and encapsulates business logic



To learn ADF do I know "Java"

I have asked by my friends and user many times that; To learn ADF do I know "Java" and if yes then which level of expertise??

Then I thought to write this post about technology/languages need to know to become ADF professional.

Following chart will show you which languages you will need to build ADF application.



J2EE vs ADF

Challenges Faced when Building J2EE Applications

  • Building J2EE applications can be complex.
  • Development time can be extensive.
  • Choosing and implementing appropriate design patterns can be overwhelming.
  • “Do it yourself” applications often repeat existing application code.
  • A large portion of “do it yourself” code is dedicated to common tasks.
  • The more code you write, the greater the chance of errors.
  • An application framework is needed.

Oracle Application Development Framework

  • Reduces the complexity of J2EE development by providing visual and declarative development
  • Increases development productivity
  • Less coding, more reuse
  • Focus on the application, not the “plumbing”
  • Provides a flexible and extensible environment by allowing multiple technology choices and development styles
  • Encourages J2EE best practices by implementing standard J2EE design patterns

ADF Concepts


The Oracle Application Development Framework (Oracle ADF) is an end-to-end
application framework that builds on J2EE standards and open-source technologies to simplify and accelerate implementing service-oriented applications. If you develop enterprise solutions that search, display, create, modify, and validate data using web, wireless, desktop, or web services interfaces, Oracle ADF can simplify your job. Used in tandem, Oracle JDeveloper 10g and Oracle ADF give you an environment that covers the full development lifecycle from design to deployment, with drag-and-drop data binding, visual UI design, and team development features built-in.

Business Component In ADF

All of these features can be summarized by saying that using ADF Business
Components for your J2EE business service layer makes your life a lot easier. The key ADF Business Components components that cooperate to provide the business service implementation are:

Entity Object

An entity object represents a row in a database table and simplifies modifying its data by handling all DML operations for you. It can encapsulate business logic for the row to ensure your business rules are consistently enforced. You associate an entity object with others to reflect relationships in the underlying database schema to create a layer of business domain objects to reuse in multiple applications.

Application Module

An application module is the transactional component that UI clients use to work with application data. It defines an updatable data model and top-level
procedures and functions (called service methods) related to a logical unit of work related to an end-user task.

View Object

A view object represents a SQL query and simplifies working with its results. You use the full power of the familiar SQL language to join, project, filter, sort, and aggregate data into exactly the “shape” required by the end-user task at hand. This includes the ability to link a view object with others to create master/detail hierarchies of any complexity. When end users modify data in the user interface, your view objects collaborate with entity objects to consistently validate and save the changes


ADF Task Flows

ADF task flows provide a modular approach for defining control flow in an application. Instead of representing an application as a single large JSF page flow, you can break it up into a collection of reusable task flows. Each task flow contains a portion of the application's navigational graph. The nodes in the task flows are activities. An activity node represents a simple logical operation such as displaying a page, executing application logic, or calling another task flow. The transactions between the activities are called control flow cases.

Task Flow Types

The two types of ADF task flow are:

Unbounded task flow: A set of activities, control flow rules, and managed beans that interact to allow a user to complete a task. An ADF unbounded task flow consists of all activities and control flows in an application that are not included within any bounded task flow.

Bounded task flow: A specialized form of task flow that, in contrast to an unbounded task flow, has a single entry point and zero or more exit points. It contains its own set of private control flow rules, activities, and managed beans. An ADF bounded task flow allows reuse, parameters, transaction management, and reentry.


JSF fragments


JSF page fragments are page definitions that run embedded in another JSF page. Fragments are like page includes in JavaServer Pages, with the difference that in Oracle ADF Faces they are usually used in the context of ADF regions or dynamic declarative components. You can also reference page fragments directly from a JSP includes tag added to a JavaServer Faces document (JSPX). However, in this case, and only if a page fragment has ADF bound content, you need to make sure the content of the page fragments ADF binding file (PageDef) is copied to the PageDef file of the parent page. Otherwise ADF queried data will not show.

ADF regions 

ADF regions consist of an ADF Faces af:region tag, an ADF bounded task flow and page fragments. Page fragments that are used in a bounded task flow don't need to copy their ADF binding references to the parent container, which is a huge difference between JSP includes and ADF regions. ADF regions define an interactive area on a view, a JSF document or another JSF page fragment, that developers use to show a single view or a complete, multi-step, process. ADF regions can be statically or dynamically defined. In either way they require a PageDef file and a bounded task flow to reference. ADF regions help building desktop like web applications in which users stay for long on a single page while working on a business task.

Declarative components


Declarative components allow developers to build a composite component out of existing ADF Faces components. Declarative components exist in two flavors: library driven and dynamic declarative components (ddc). The tag library driven components are declaratively built from the File | New menu option. In the JSF view option you find a declarative component menu option that steps you through building your own ADF F aces component from existing ADF Faces components. You use tag library driven declarative components to build custom components with behavior, like a tool bar or a custom file-upload handler. The goal of building declarative components is to build re-usable components that simplify development and administration by avoiding duplicate page codes. Dynamic declarative components (DDC) are used within the scope of the web application they are defined in and cannot be re-used across applications. Their main usage is to build reusable layout artifacts or page area components. For example, a custom tab canvas is what you would build using DDC components.

Page templates


Page templates are layout definitions that you use as a starter when building new pages to enforce consistent page layouts throughout applications and enterprises. Best practices are to build a page template using the ADF Faces Quick start templates. You cannot nest page templates, but you can use page templates on parent and child views (page fragments). A page template is the page level equivalent to a DDC component.

ADF Library


ADF libraries are special Oracle ADF archive files that you use to reuse bounded task flows (regions), page templates and declarative components. They are standard JAR files with extra information in the archive manifest file that allows you to import the library files into the Oracle JDeveloper Resource Palette for declarative reuse.