tion launches with the index page shown in
Figure 1. Click the Customer Care Center link
or tab to start exploring the application’s
functionality. (Customer Care Center is the
only option enabled; the other links and tabs
are placeholders included for illustrative
purposes only.)
The Customer Care Center module, shown
in Figure 2, enables users to browse and edit
customers and customer orders. At runtime,
the contents of the page area that initially
shows the welcome image are dynamically
replaced with customer or order data that the
user selects via a link, a tab, or a context menu.
REUSABLE PAGE FLOWS
Reusable page flows—known as Oracle ADF
task flows—are at the heart of the Dynamic
Tabs UI Shell template. Bounded task flows
enable you to define reusable page navigation flows that model a specific business use
case—such as the create, read, update, and
delete (CRUD) operation for a customer or an
order entity.
The sample application uses three
bounded task flows to handle the customer
and order CRUD use cases:
•;CustomerOrdersCRUD-btf enables users to
browse and edit the orders belonging to a
selected customer.
•;CustomersCRUD-btf enables users to
edit customer accounts and create new
customers.
•;OrderItemsCRUD-btf is referenced from
the CustomerOrdersCRUD-btf task flow to
edit the line items for a customer order.
Bounded task flows can be developed
based on task flow templates, which you
define visually and declaratively in Oracle
JDeveloper and use by either direct reference or copy. Task flow templates expose
the same set of properties as bounded task
flows. For input parameter and navigation
flow consistency, the sample application’s
bounded task flows were developed based on
a reusable common task flow template. The
task flow template contains the configuration for a managed bean that is referenced
by predefined task flow input parameters.
One of the template’s input parameters is
tabContext, which prepares task flows that
are based on the task flow template to be
used in the context of the Dynamic Tabs UI
Shell template. Defining a managed bean in
the task flow template to hold input parameter values enables you to expose an easy-to-discover, easy-to-use API for predefined
input parameters such as tabContext.
The SummitADFUIShell application does
not contain the task flow source code, referencing it instead from Oracle ADF libraries.
The task flow source files reside in the
dynamic TabShellSample -> ReusableModules
-> Bounded TaskFlows folder, located
under the main application directory. The
Bounded TaskFlows folder also contains
Bounded TaskFlows.jws, a workspace you can
open and explore in Oracle JDeveloper.
DISPLAYING TASK FLOWS ON A PAGE
The Dynamic Tabs UI Shell template supports applications that enable the type of
multitasking that call center agents must do,
such as looking at the data of the customer
currently on the phone while bringing up
the data of the next customer in the queue.
For this purpose, the Dynamic Tabs UI Shell
template leverages Oracle ADF regions,
which enable bounded task flows to run isolated in specific areas of a page.
Executing bounded task flows in an
Oracle ADF region requires development of
task flows with page fragments that render
the views—a configuration option you
specify in the task flow creation dialog box.
The Dynamic Tabs UI Shell template then
exposes APIs that enable you to manage
these regions programmatically within
UI Shell tabs.
globalToolbar
globalTabs
innerToolbar
navigation
logo brandingTitle
copyright
Figure 3: Dynamic Tabs UI Shell template design
LAYING OUT CONTENT IN THE DYNAMIC
TABS UI SHELL TEMPLATE
The Dynamic Tabs UI Shell template is
applied to top-level pages in an Oracle ADF
Faces application. In Oracle JDeveloper 11 g
Release 2, a top-level page is a JavaServer
Faces (JSF) 2.0 Facelets document that can
be run standalone to display in a browser.
You use the Dynamic Tabs UI Shell template
to partition the main application page (the
index page) into different functional areas,
such as customer care, storefront, and shipping. Each functional area has its own top-level page that also references the Dynamic
Tabs UI Shell template. With this modular
architecture, you can easily assemble top-level pages into a single application.
As shown in Figure 3, the template layout
is broadly organized into a header area, a
main area, and a footer area.
The header area contains the page logo, a
branding title, and an area for placing global
navigation links and search. You configure the
logo and the title through template properties
exposed in the Oracle JDeveloper Property
Inspector feature. The link and search area are
facets into which you can drag and drop Oracle
ADF Faces components. These facets are
simply placeholders for grouping components
in a specific area of a parent component, such
as a template. Facets that are left empty do
not appear in the rendered page at runtime.
The template’s main area supports global
and local navigation. Global navigation—
that is, switching among top-level pages—is
performed by global tabs (represented by the
globalLinks
globalSearch
Local Area
status
about