How the Cordova Plugin Simplifies Development in Oracle MAF

Simplify Development in Oracle MAF hero image

Java is one of the most commonly used programming languages. It has a lot of components that are specifically used by Cordova DatePicker, one such component allows you to select date and time in the mobile application.

Recently, I had the opportunity to work on Oracle MAF technology where I met a time-consuming task of having to select each date individually in the application. With the use of the Cordova DatePicker plugin, the task was completed in very little time.

 

What is Cordova?

Cordova is a platform which allows developers to add different native functionality to their applications such as camera, maps, email using HTML5, CSS, and JavaScript.

Apache Cordova allows wrapping up of CSS, HTML, and JavaScript code and extends the application across multiple platforms, avoiding each mobile platform native development language.

Cordova offers plugins to access the device functionalities such as email, calendar, camera etc.

 

The Use of Cordova Plugins in Oracle Mobile Application Framework

Oracle Mobile Application Framework (MAF) is a framework that allows developers to develop a single application which can run on different platforms such as Google Android, Apple iOS, and Microsoft Windows.

MAF enables the application to interact with the device on which you deploy the application. It offers default plugins knows as Core plugins and allow you to register other plugins to meet the requirements.

MAF includes the following versions of Apache Cordova for applications that use plugins:

  • Apache Cordova 3.6.3 for MAF applications on the Android platform
  • Apache Cordova 3.7.0 for MAF applications on the iOS platform

 

Implementing Cordova DatePicker Plugin:

You can also use the following to select time only by replacing the word mode to ‘time’.

To implement this, we need to install Cordova plugin from the following link:

  • Local development workflow using Cordova CLI
    Cordova plugin add Cordova-plugin-DatePicker
  • Local development workflow using Phone Gap CLI
    Phone gap local plugin add Cordova-plugin datepicker

The example of the Cordova DatePicker makes it more convenient in addressing the process of selecting the date and time within the application.

Including DatePicker, there are many other Cordova plugins that make application development easier such as:

  • Barcode Scanner allows extracting data from a QR code or barcode from a device.
    Cordova plugin add Cordova-plugin-barcode scanner
  • Beacon allows the app to displays the nearest ranged beacon and a list of region enter/exit events
    Cordova plugin add Cordova-plugin-beacon
  • Geolocation gives device location
    Cordova plugin add Cordova-plugin-geolocation
  • FingerPrint helps scan the fingerprint of your user with the TouchID sensor
    Cordova plugin add Cordova-plugin-android-fingerprint-auth

 

In my next post, I will discuss how these plugins make application development easier.