User:Sai Krishna Panakanti/sandbox

Apache Cordova (formerly PhoneGap) is a popular mobile application development framework originally created by Nitobi. Adobe Systems purchased Nitobi in 2011, rebranded it as PhoneGap, and later released an open source version of the software called Apache Cordova. Apache Cordova enables software programmers to build applications for mobile devices using CSS3, HTML5, and JavaScript instead of relying on platform-specific APIs like those in Android, iOS, or Windows Phone. It enables wrapping up of CSS, HTML, and JavaScript code depending upon the platform of the device. It extends the features of HTML and JavaScript to work with the device. The resulting applications are hybrid, meaning that they are neither truly native mobile application (because all layout rendering is done via Web views instead of the platform's native UI framework) nor purely Web-based (because they are not just Web apps, but are packaged as apps for distribution and have access to native device APIs). Mixing native and hybrid code snippets have been possible since version 1.9.

The software was previously called just "PhoneGap", then "Apache Callback". As open-source software, Apache Cordova allows wrappers around it, such as Appery.io or Intel XDK.

PhoneGap is Adobe’s productised version and ecosystem on top of Cordova. Like PhoneGap, many other tools and frameworks are also built on top of Cordova, including Ionic, Monaca, TACO, the Intel XDK, and the Telerik Platform. These tools use Cordova, and not PhoneGap for their core tools.

Contributors to the Apache Cordova project include Adobe, BlackBerry, Google, IBM, Intel, Microsoft, Mozilla, and others.

History
First developed at an iPhoneDevCamp event in San Francisco, PhoneGap went on to win the People's Choice Award at O'Reilly Media's 2009 Web 2.0 Conference, and the framework has been used to develop many apps. Apple Inc. has confirmed that the framework has its approval, even with the new 4.0 developer license agreement changes. The PhoneGap framework is used by several mobile application platforms such as Monaca, appMobi, Convertigo  , ViziApps, and Worklight  as the backbone of their mobile client development engine.

Adobe officially announced the acquisition of Nitobi Software (the original developer) on October 4, 2011. Coincident with that, the PhoneGap code was contributed to the Apache Software Foundation to start a new project called Apache Cordova. The project's original name, Apache Callback, was viewed as too generic. Then, it also appears in Adobe Systems as Adobe PhoneGap and also as Adobe Phonegap Build.

Early versions of PhoneGap required an Apple computer to create iOS apps and a Windows computer to create Windows Mobile apps. After September 2012, Adobe's PhoneGap Build service allows programmers to upload CSS, HTML, and JavaScript source code to a "cloud compiler" that generates apps for every supported platform. In 2013, an Apache Cordova moved into npm.

Supported Strategy
Any developer, before designing an application, must decide on a strategy. There are three commonly used plans.
 * Native Mobile App
 * Mobile Web App
 * Hybrid Mobile App

Native Mobile Apps
Native Mobile Apps are specific to the operating system on which they are running. The OS provides built-in APIs to execute it locally.

Mobile Web Apps
Mobile Web Apps are apps developed to run on any mobile web browser. It makes less use of the built-in APIs of the operating system when compared to that of the native applications.

Hybrid Mobile Apps
Hybrid Mobile App is a mix of both Native Mobile App and Mobile Web App.

Cordova supports two basic workflows to support the above defined mobile app development paths
 * Cross-platform (CLI) Workflow: This path is chosen for developing Mobile Web App
 * Platform-centered Workflow: This path is chosen for developing Native Mobile App

Architecture
The architecture of the framework changes based on the requirements of the application but most data-driven applications follow the basic workflow i.e., a user interacts with the client, the data from the user is passed on to the server, and finally, server talks to the database. Apache Cordova understands this aspect and helps developers with the first two stages. With the advancement of smartphones and IoT, now a client can take information in various forms.Apache Cordova eases the task of the developer by processing this information. The high-level architecture of Cordova has three major components.
 * Web View
 * Web App
 * Plugins

Web View
The WebView is like a web browser. It is where web pages are arranged in a pre-defined manner and the user can interact with them. Apache Cordova uses HTML5 for displaying the web pages. On the web page, the user can fill out forms, click a button among other things.

Web App
The application program resides in this module. The webserver directory index is located in this level, which references to all the CSS, JavaScript, images, media files, or other resources necessary for the framework to run. Developers, who are interested in changing the design of the web page, work is this section of the hierarchy.

Plugins
The plugins are most integral part of the Apache Cordova platform. With the help of native components of the underlying Operating System, Cordova breaks down the information provided by the user via WebView and forwards the data which the server can understand. Apache Cordova has 2 types of plugins - core plugins and custom plugins. Basically, core plugins is the native code that is made available by the Operating System, whereas, custom ones are programmed to help developers complete specific operations.

Design and rationale
The core of Apache Cordova applications use CSS3 and HTML5 for their rendering and JavaScript for their logic. HTML5 provides access to underlying hardware such as the accelerometer, camera, and GPS. However, browsers' support for HTML5-based device access is not consistent across mobile browsers, particularly older versions of Android. To overcome these limitations, Apache Cordova embeds the HTML5 code inside a native WebView on the device, using a foreign function interface to access the native resources of it.

Apache Cordova can be extended with native plug-ins, allowing developers to add more functionalities that can be called from JavaScript, making it communicate directly between the native layer and the HTML5 page. These plugins allow access to the device's accelerometer, camera, compass, file system, microphone, and more.

However, the use of Web-based technologies leads some Apache Cordova applications to run slower than native applications with similar functionality. Adobe Systems warns that applications may be rejected by Apple for being too slow or not feeling "native" enough (having appearance and functionality consistent with what users have come to expect on the platform). This can be an issue for some Apache Cordova applications.

Supported platforms
Apache Cordova currently supports development for the operating systems Apple iOS, Bada, BlackBerry, Firefox OS, Google Android, LG webOS, Microsoft Windows Phone (7 and 8), Nokia Symbian OS, Tizen (SDK 2.x), and Ubuntu Touch. The table below is a list of supported features for each operating system.

Pros

 * PhoneGap allows easy deployment of an already existing web application in one or more mobile application stores.
 * Open source and available for free.
 * With several available plugins, Apache Cordova enables the developers to build cross-platform applications without having to learn a new language.

Cons

 * The performance of Cordova/PhoneGap apps has often been criticised. There are high chances of native UI outperforming a hybrid solution. However, improvements in hardware and implementations might narrow the gap.