Skip Headers
Oracle® Fusion Middleware Mobile Developer's Guide for Oracle Application Development Framework
11g Release 2 (11.1.2.3.0)

Part Number E24475-01
Go to Documentation Home
Home
Go to Table of Contents
Contents
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
PDF · Mobi · ePub

2 Introduction to ADF Mobile Application Development

This chapter describes the development approach for ADF Mobile applications.

This chapter includes the following sections:

2.1 Introduction to ADF Mobile Application Development

To ensure the best design for your ADF Mobile application, Oracle recommends that you follow an iterative, step-by-step development process.

Although you can develop the application features in addition to the ADF Mobile application itself, this workflow is not necessarily the standard case; application development involves creating the ADF Mobile application and embedding the application features that can be created by other developers. In other words, you create an ADF Mobile application by combining content that you create yourself with the content that was developed separately by someone else and then integrated into the ADF Mobile application. Knowing Xcode or Android application development is not a prerequisite for creating either the ADF Mobile application itself or the specific content for an application feature.

For more information, see Chapter 4, "Getting Started with ADF Mobile Application Development."

2.2 Infrastructure Requirements

Although development needs vary depending on the target platform, the minimum requirements for creating, building, and testing an ADF Mobile application are as follows:

For more information on prerequisites, see Section 3.2, "Prerequisites for Developing ADF Mobile Applications."

2.3 Supported Platforms, Devices, and Databases

ADF Mobile supports the following platforms:

The following mobile devices are supported:

The supported database is SQLite (see Chapter 11, "Using the Local Database").

2.4 ADF Mobile Application Architecture

The following are potential architectures for your ADF Mobile application:

For more information, see the following:

2.5 Typical Development Stages

Typically, you perform the following activities when building an ADF Mobile application:

The steps you take to build your ADF Mobile application will generally occur as follows:

  1. During the design stage, consider the tasks a mobile user will be performing, keeping in mind that hand-held usage is different from that of a laptop or desktop computer. How will your ADF Mobile application help users get their jobs done? How will the users interact with the device? The more streamlined the application, the more they will use it.

    The next steps are to determine whether the application is required to work in a connected or disconnected mode; understand the device services integration requirements; determine the server-side data source and protocol.

    When designing server-side services, it is critical to provide for optimization for the mobile access: if server-side web services are very complex, it would be difficult for the mobile application to consume them. This is not only due to the amount of data that needs to be passed, but also the amount of the client-side logic that must be written to process the results. It is preferable to expose a set of server-side interfaces provided specifically for mobile. You also need to understand the client business services that must be developed, such as all Java modules and data controls that need to be created. In addition, you should create wireframes for the views and task flow in the application, which can help you to visualize the application functionality and assist in the development process.

    As a final design step, you should consider how to partition the application functionality into separate application features that represent a group of functionality and associated views. Then you can start designing the client user interface and task flows by creating wireframes.

  2. When setting up your work environment, download and install the ADF Mobile extension, and then install the necessary components and complete the required setup for development and deployment. For more information, see Chapter 3, "Setting Up the ADF Mobile Environment."

  3. When creating your ADF Mobile application using JDeveloper, you use the ADF Mobile application creation wizard. The artifacts that result from creating the application include descriptor files for the ADF Mobile application and for the application features, default images for icons and tabs for all supported platforms, and a set of data controls used for accessing the services of a mobile device (such as camera, GPS, or email).

    For more information, see the following:

  4. When implementing the application features, you perform a thorough evaluation of the business need to determine which application features should be included within the ADF Mobile application. Using the overview editors provided by ADF Mobile, your tasks for implementing an application feature include identifying its type (HTML, remote URL, or ADF Mobile AMX, or native UI), its display properties (display name, navigation bar and springboard icon), and its display behavior as dictated by both the mobile device capabilities and the user role.

    For more information, see the following:

  5. During the application deployment stage, you start with creating a deployment profile that will support devices and simulators for its respective platform. Creating a deployment profile may include selecting the display icon used for the ADF Mobile application itself in various orientations (such as landscape or portrait) and setting the application's signing options (such as debug or release).

    You then proceed to deploying your application to the mobile device or simulator.

    Note:

    With ADF Mobile applications, it is required that you deploy to the device or simulator before attempting any testing and debugging (see Chapter 18, "Testing and Debugging ADF Mobile Applications"). The application cannot be run until you deploy it.

    For more information, see Chapter 16, "Deploying ADF Mobile Applications."

  6. During the testing and debugging stage, you test, debug, and optimize your application. For more information, see Chapter 18, "Testing and Debugging ADF Mobile Applications."

  7. Enabling and configuring security for the application typically requires configuring the login server, such as the Oracle Identity Connect server, or it can be any web page protected by the basic HTTP authentication mechanism. In addition, you may have to configure the access control server.

    For more information, see Chapter 17, "ADF Mobile Application Security."

  8. After ensuring that your application functions as expected at a basic level, you can implement the Java code to access the server-side data:

    • For connected applications, these Java classes should invoke web services directly. If your application uses SOAP or REST XML-based data sources, you invoke web services through data controls, with the assistance of a set of helper classes that you can invoke from your code to invoke the data controls and return data. If your application uses JSON-based data sources, your code should directly invoke the JSON service and return data, after which you need to parse the JSON data from the server and populate the objects holding data collections accordingly.

    • For disconnected applications, your code should populate the local SQLite database. Then, the code that backs the user interface can retrieve data from the SQLite database instead of directly invoking web services.

    For more information, see the following:

  9. During the second round of deployment, you ensure that after adding security to your application and enabling access to the server-side data the application deployment runs as expected and the application is ready for the final testing and debugging.

  10. During the final round of testing and debugging, you focus on the security and the server-side data access functionality ensuring that their integration into the application did not result in errors and unexpected behavior.

  11. Deploying the application to the production environment typically involves publishing to an enterprise server, the Apple App Store, or an application marketplace, such as Google Play. After you publish the ADF Mobile application, end users can download it to their mobile devices and access it by clicking the designated icon (see Appendix C, "ADF Mobile Application Usage"). The application features bear the designated display icons and display as appropriate to the end user and the user's device.

2.6 The Application Lifecycle

The lifecycle of an ADF Mobile application is driven by events that occur at the levels of the mobile device operating system, the JVM, and ADF Mobile. The application's reaction to these events is enabled through the use of the LifeCycleListener's methods. For more information, see Section 5.6, "About Lifecycle Event Listeners."

2.7 Sample Applications

After setting up your development environment (see Chapter 3, "Setting Up the ADF Mobile Environment"), you can examine ADF Mobile sample applications located in the PublicSamples.zip file within the jdev_install/jdeveloper/jdev/extensions/oracle.adf.mobile/Samples directory on your development computer.

The sample applications demonstrate the following:

For more information, see Appendix E, "ADF Mobile Sample Applications."

2.8 ADF Mobile AMX Application Feature

ADF Mobile AMX is basically a subframework within ADF Mobile and provides a set of layout, field, and data components that enable you to create an application feature that behaves appropriately for both the iOS and Android user experience. ADF Mobile AMX supports some of Oracle ADF components, data controls, bindings, and the Expression Language that belong to the following layers:

Differences in every layer exist due to the inherent differences between a mobile application and a web application. For more information, see Section 2.9, "Comparison of ADF Mobile and Server-Based Oracle ADF."

2.9 Comparison of ADF Mobile and Server-Based Oracle ADF

Table 2-1 summarizes the functionality, components, and technologies supported by ADF Mobile and compares them to those supported by a server-based Oracle ADF application.

Table 2-1 Differences Between ADF Mobile and Server-Based Oracle ADF Application

Layer Supported by ADF Mobile Supported by Server-Based Oracle ADF

ADF Model

  • SOAP, REST XML, and REST JSON-based data sources and data controls

  • Subset of the model layer Java (for example, there is no support for Java web service proxy)

  • JDBC

Full range of data sources and data controls

View

  • Locally rendered ADF Mobile AMX or custom HTML5 pages.

  • HTML pages rendered on the server.

  • Server-rendered only

  • ADF Faces rich client and Trinidad JSF components

Controller

For ADF Mobile AMX application feature (see Section 2.8, "ADF Mobile AMX Application Feature"):

  • Subset of Oracle ADF task flow components

  • Logic resides on the mobile device

Full ADF task flow

Java Support

JavaME CDC and Java 1.4

Java EE with the latest Java


As described in Table 2-1, in the view layer, ADF Mobile provides you with an option of using locally rendered or server-rendered views to present the user interface. ADF Mobile AMX enables the most seamless user experience. For the server-based Oracle ADF, the user interface is rendered on the server and is primarily provided through ADF Faces rich client components or Trinidad components, both of which are based on the JSF technology.

In the controller layer, an abbreviated version of the ADF task flow that supports a subset of components is provided when ADF Mobile AMX contents are used in a mobile application. ADF Mobile task flow supports views, control flow case, wild card control flow case, method calls, and routers, but does not support regions. In ADF Mobile, the page flow logic resides entirely on a mobile device, enabling the page navigation without a round trip to the server.

In the ADF Model layer, ADF Mobile supports SOAP, REST XML, and REST JSON as the server-side data sources. In addition, ADF Mobile supports JDBC connection and APIs to the local database, but it does not support ADF business components. Furthermore, ADF Mobile does not implement all of the Java methods supported by the server-based ADF. For example, you cannot use the programmatic access binding context. Instead, you can access the binding data by invoking the Expression Language (EL) expressions. In addition, since ADF Mobile does not support the Java proxy for web services, to access web services programmatically, you must use data controls in conjunction with the web services invocation helper classes.

For Java support, ADF Mobile's embedded Java virtual machine follows the JavaME CDC specification, which is based on Java 1.4, meaning that you cannot use any Java 1.5 or later features in your Java code.