SlideShare a Scribd company logo
1 of 14
Introduction to




         ejlp12@gmail.com
Apache Cordova



Apache Cordova is a platform for building natively installed
mobile applications using HTML, CSS and JavaScript
History


Apache Cordova was originally called Phonegap build by Nitobi
Open-source & free software from the beginning (MIT License), Apache
License now
Nitobi then aquired by Adobe and donated the PhoneGap codebase to the
Apache Software Foundation (ASF)
PhoneGap is still a product of Adobe. It is a distribution of Apache Cordova.
Think of Apache Cordova as the engine that powers PhoneGap.
Cordova Architecture
Apache Cordova Application’s User Interface


 The user interface for Apache Cordova applications
 is created using HTML, CSS, and JavaScript.
 The UI layer is a web browser view that takes up
 100% of the device width and 100% of the device
 height.
 The web view used by application is the same web
 view used by the native operating system
    iOS: Objective-C UIWebView class
    Android: android.webkit.WebView
    WP7: WebBrowser
    WP8: WebBrowser control (Internet Explorer 10)
    BlackBerry: WebWorks framework
Apache Cordova API



Provides an application programming interface (API)
  enables you to access native operating system functionality using
  JavaScript.
  APIs for Accelerometer, Camera, Compass, Media, FileSystem, etc
  Extendable using native plug-in
docs.phonegap.com




                                   Cordova JavaScript API
             Cordova Application            and             Native API
                                   Cordova Native Library
Supported Platforms


Accelerometer
        Monitor the motion sensor on the device.
Camera
        Take pictures with the device camera
        allow the user to select images from their photo
        library on the device.
Capture
        Capture video and still images from the camera, and
        audio from the microphone.
Compass
        Give users of your app some direction.
Contacts
        Search and Create contacts in the user’s address
        book.
File
        Low level read and write access to the file system.
        Upload and download files from a web server.
GeoLocation
        Make your app location aware.
Media
        Play and record audio files.
Network
        Monitor the device connections
Notification
        Access to vibration, beep and alerts.
Storage                                                       Updated list:
        Persistent data store in WebStorage.
                                                              http://wiki.apache.org/cordova/PlatformSupport
Development using Cordova


Tools for development
  Any HTML & JS editor
  Platform SDK e.g. Android SDT, Android SDK, BB SDK, Xcode, Visual
  Studio Mobile.
  Platform Emulator (usually provide along with SDK)
  JS/HTML GUI Mobile framework e.g. JQuery, Sencha Touch, dojo Mobile
  Browser e.g. Firefox with Bugzilla extension, Chrome Browser
Getting Started


Guides:
•   Getting Started with Android
•   Getting Started with Blackberry
•   Getting Started with iOS
•   Getting Started with Symbian
•   Getting Started with WebOS
•   Getting Started with Windows Phone
•   Getting Started with Windows 8
•   Getting Started with Bada
•   Getting Started with Tizen

             http://docs.phonegap.com/en/2.2.0/guide_getting-started_index.md.html

Use platform SDK to develop application for each target platform


                                                                                               …
    Xcode             Android SDK           BB Java Eclipse Plug-in   Visual Studio, Windows
                      Eclipse ADT Plug-in   Ripple                    Phone Dev Tools
Code Example
<!DOCTYPE html>
<html>
  <head>
    <title>Device Properties Example</title>
    <script type="text/javascript" charset="utf-8" src="cordova-2.0.0.js"></script>
    <script type="text/javascript" charset="utf-8">
    // Wait for Cordova to load
    document.addEventListener("deviceready", onDeviceReady, false);

   // Cordova is ready
   function onDeviceReady() {
       navigator.geolocation.getCurrentPosition(onSuccess, onError);
   }

   // onSuccess Geolocation
   function onSuccess(position) {
       var element = document.getElementById('geolocation');
       element.innerHTML = 'Latitude: '           + position.coords.latitude          +   '<br   />'   +
                           'Longitude: '          + position.coords.longitude         +   '<br   />'   +
                           'Altitude: '           + position.coords.altitude          +   '<br   />'   +
                           'Accuracy: '           + position.coords.accuracy          +   '<br   />'   +
                           'Altitude Accuracy: ' + position.coords.altitudeAccuracy   +   '<br   />'   +
   }

    // onError Callback receives a PositionError object
    function onError(error) {
        alert('code: ' + error.code + 'n' + message: ' + error.message + 'n');
    }
    </script>
  </head>
  <body>
    <p id="geolocation">Finding geolocation...</p>
  </body>
</html>
Apache Cordova Native Plug-in


What if a native feature isn’t available in Core APIs?

PhoneGap is extensible with a “native plugin” model that enables you
to write your own native logic to access via JavaScript.

  You develop your JavaScript class to
  mirror the API of the native class
  Invoke the native function using
  PhoneGap.exec()
  Plug-in class mappings:
      Android: res/xml/plugins.xml
      iOS: www/Cordova.plist
      BlackBerry: www/plugins.xml


PhoneGap.exec(function(winParam){}, function(error){}, ”service”, ”action", [params]);
Plugin Example (Android Native Code)

package sample.cordova.plugin;

import   org.apache.cordova.api.CordovaPlugin;
import   org.apache.cordova.api.PluginResult;
import   org.json.JSONArray;
import   org.json.JSONException;
import   org.json.JSONObject;

/**
 * This class echoes a string called from JavaScript.
                                                        Extend the Cordova                   Implement execute
 */
                                                            Plugin class                          method
public class Echo extends CordovaPlugin {
    @Override
    public boolean execute(String action, JSONArray args, CallbackContext callbackContext)
    throws JSONException {
                                                                Define and handle
        if (action.equals("echo")) {                                   action
            String message = args.getString(0);
            if (message != null && message.length() > 0) {
                callbackContext.success(message);
            } else {
                callbackContext.error("Expected one non-empty string argument.");
            }
            return true;
        }
        return false;
    }

}
Plugin Example (HTML + JS Code)

<!DOCTYPE html>
<html>
  <head>
    <title>Cordova Plugin Test</title>
    <script type="text/javascript" charset="utf-8" src="cordova-2.0.0.js"></script>
    <script type="text/javascript" charset="utf-8">
    var EchoPlugin = {
         callNativeFunction: function (success, fail, resultType) {
             return Cordova.exec( success, fail, “sample.cordova.plugin.Echo", "echo", [resultType]);
         }
    };

    function callNativePlugin( returnSuccess ) {
         HelloPlugin.callNativeFunction( nativePluginResultHandler, nativePluginErrorHandler, returnSuccess );
    }
    function nativePluginResultHandler (result) {
         alert("SUCCESS: rn"+result );
    }
    function nativePluginErrorHandler (error) {
         alert("ERROR: rn"+error );
    }
    </script>
  </head>
  <body>
<body onload="onBodyLoad()">
<h1>Cordova Plugin Test</h1>
<button onclick="callNativePlugin('success');">Click to invoke the Native Plugin!</button>
</body>
Resources


Apache Cordova Website
http://cordova.apache.org/
Apache Cordova Documentation
http://docs.phonegap.com/en/2.2.0/index.html

PhoneGap Day 2011 – IBM, PhoneGap and the Enterprise by Bryce Curtis [Aug 10, 2011]
http://www.slideshare.net/drbac/phonegap-day-ibm-phonegap-and-the-enterprise (video)
Andrew Trice’s Blog
http://www.tricedesigns.com/category/cordova/

More Related Content

What's hot

Introduction to Android Development
Introduction to Android DevelopmentIntroduction to Android Development
Introduction to Android DevelopmentAly Abdelkareem
 
Introduction To Mobile Application Development
Introduction To Mobile Application DevelopmentIntroduction To Mobile Application Development
Introduction To Mobile Application DevelopmentSyed Absar
 
Introduction to mobile application development
Introduction to mobile application developmentIntroduction to mobile application development
Introduction to mobile application developmentChandan Maurya
 
Typescript ppt
Typescript pptTypescript ppt
Typescript pptakhilsreyas
 
Serverless computing - Build and run applications without thinking about servers
Serverless computing - Build and run applications without thinking about serversServerless computing - Build and run applications without thinking about servers
Serverless computing - Build and run applications without thinking about serversAmazon Web Services
 
Introduction to fragments in android
Introduction to fragments in androidIntroduction to fragments in android
Introduction to fragments in androidPrawesh Shrestha
 
Introduction to Mobile Application Development
Introduction to Mobile Application DevelopmentIntroduction to Mobile Application Development
Introduction to Mobile Application DevelopmentTharindu Dassanayake
 
React Js Simplified
React Js SimplifiedReact Js Simplified
React Js SimplifiedSunil Yadav
 
Android Development: The Basics
Android Development: The BasicsAndroid Development: The Basics
Android Development: The BasicsMike Desjardins
 
Basic of Android App Development
Basic of Android App DevelopmentBasic of Android App Development
Basic of Android App DevelopmentAbhijeet Gupta
 
Consuming Web Services in Android
Consuming Web Services in AndroidConsuming Web Services in Android
Consuming Web Services in AndroidDavid Truxall
 
Kotlin Language powerpoint show file
Kotlin Language powerpoint show fileKotlin Language powerpoint show file
Kotlin Language powerpoint show fileSaurabh Tripathi
 
Native, Web or Hybrid Mobile App Development?
Native, Web or Hybrid Mobile App Development?Native, Web or Hybrid Mobile App Development?
Native, Web or Hybrid Mobile App Development?Sura Gonzalez
 
Android Web app
Android Web app Android Web app
Android Web app Sumit Kumar
 
Cross platform mobile application devlopment
Cross platform mobile application devlopmentCross platform mobile application devlopment
Cross platform mobile application devlopmentPrabhat gangwar
 
android layouts
android layoutsandroid layouts
android layoutsDeepa Rani
 
React JS - A quick introduction tutorial
React JS - A quick introduction tutorialReact JS - A quick introduction tutorial
React JS - A quick introduction tutorialMohammed Fazuluddin
 

What's hot (20)

Introduction to Android Development
Introduction to Android DevelopmentIntroduction to Android Development
Introduction to Android Development
 
Introduction To Mobile Application Development
Introduction To Mobile Application DevelopmentIntroduction To Mobile Application Development
Introduction To Mobile Application Development
 
Learn react-js
Learn react-jsLearn react-js
Learn react-js
 
Introduction to mobile application development
Introduction to mobile application developmentIntroduction to mobile application development
Introduction to mobile application development
 
Typescript ppt
Typescript pptTypescript ppt
Typescript ppt
 
Serverless computing - Build and run applications without thinking about servers
Serverless computing - Build and run applications without thinking about serversServerless computing - Build and run applications without thinking about servers
Serverless computing - Build and run applications without thinking about servers
 
Introduction to fragments in android
Introduction to fragments in androidIntroduction to fragments in android
Introduction to fragments in android
 
Introduction to Mobile Application Development
Introduction to Mobile Application DevelopmentIntroduction to Mobile Application Development
Introduction to Mobile Application Development
 
React Js Simplified
React Js SimplifiedReact Js Simplified
React Js Simplified
 
Android Development: The Basics
Android Development: The BasicsAndroid Development: The Basics
Android Development: The Basics
 
Basic of Android App Development
Basic of Android App DevelopmentBasic of Android App Development
Basic of Android App Development
 
Consuming Web Services in Android
Consuming Web Services in AndroidConsuming Web Services in Android
Consuming Web Services in Android
 
Kotlin Language powerpoint show file
Kotlin Language powerpoint show fileKotlin Language powerpoint show file
Kotlin Language powerpoint show file
 
Native, Web or Hybrid Mobile App Development?
Native, Web or Hybrid Mobile App Development?Native, Web or Hybrid Mobile App Development?
Native, Web or Hybrid Mobile App Development?
 
Android Web app
Android Web app Android Web app
Android Web app
 
ReactJS presentation.pptx
ReactJS presentation.pptxReactJS presentation.pptx
ReactJS presentation.pptx
 
React Native
React NativeReact Native
React Native
 
Cross platform mobile application devlopment
Cross platform mobile application devlopmentCross platform mobile application devlopment
Cross platform mobile application devlopment
 
android layouts
android layoutsandroid layouts
android layouts
 
React JS - A quick introduction tutorial
React JS - A quick introduction tutorialReact JS - A quick introduction tutorial
React JS - A quick introduction tutorial
 

Viewers also liked

Apps with Apache Cordova and Phonegap
Apps with Apache Cordova and PhonegapApps with Apache Cordova and Phonegap
Apps with Apache Cordova and PhonegapChristian Grobmeier
 
Phonegap/Cordova vs Native Application
Phonegap/Cordova vs Native ApplicationPhonegap/Cordova vs Native Application
Phonegap/Cordova vs Native ApplicationMuhammad Hakim A
 
Cordova / PhoneGap, mobile apps development with HTML5/JS/CSS
Cordova / PhoneGap, mobile apps development with HTML5/JS/CSSCordova / PhoneGap, mobile apps development with HTML5/JS/CSS
Cordova / PhoneGap, mobile apps development with HTML5/JS/CSSGabriel Huecas
 
Cordova and PhoneGap Insights
Cordova and PhoneGap InsightsCordova and PhoneGap Insights
Cordova and PhoneGap InsightsMonaca
 
Cordova: APIs and instruments
Cordova: APIs and instrumentsCordova: APIs and instruments
Cordova: APIs and instrumentsIvano Malavolta
 
All About Phonegap
All About Phonegap All About Phonegap
All About Phonegap Sushan Sharma
 
Introduction to jQuery Mobile
Introduction to jQuery MobileIntroduction to jQuery Mobile
Introduction to jQuery Mobileejlp12
 
Hybrid App Development with PhoneGap
Hybrid App Development with PhoneGapHybrid App Development with PhoneGap
Hybrid App Development with PhoneGapDotitude
 
[2015/2016] Apache Cordova
[2015/2016] Apache Cordova[2015/2016] Apache Cordova
[2015/2016] Apache CordovaIvano Malavolta
 
JBoss Data Virtualization (JDV) Sample Physical Deployment Architecture
JBoss Data Virtualization (JDV) Sample Physical Deployment ArchitectureJBoss Data Virtualization (JDV) Sample Physical Deployment Architecture
JBoss Data Virtualization (JDV) Sample Physical Deployment Architectureejlp12
 
Linux container & docker
Linux container & dockerLinux container & docker
Linux container & dockerejlp12
 
Agile & SCRUM
Agile & SCRUMAgile & SCRUM
Agile & SCRUMejlp12
 
IBM WebSphere Application Server (Clustering) Concept
IBM WebSphere Application Server (Clustering) ConceptIBM WebSphere Application Server (Clustering) Concept
IBM WebSphere Application Server (Clustering) Conceptejlp12
 
RESTful web service with JBoss Fuse
RESTful web service with JBoss FuseRESTful web service with JBoss Fuse
RESTful web service with JBoss Fuseejlp12
 
PMP Training - 12 project procurement management
PMP Training - 12 project procurement managementPMP Training - 12 project procurement management
PMP Training - 12 project procurement managementejlp12
 
PMP Training - 08 project quality management
PMP Training - 08 project quality managementPMP Training - 08 project quality management
PMP Training - 08 project quality managementejlp12
 
PMP Training - 04 project integration management
PMP Training - 04 project integration managementPMP Training - 04 project integration management
PMP Training - 04 project integration managementejlp12
 
PMP Training - 06 project time management2
PMP Training - 06 project time management2PMP Training - 06 project time management2
PMP Training - 06 project time management2ejlp12
 

Viewers also liked (20)

Apps with Apache Cordova and Phonegap
Apps with Apache Cordova and PhonegapApps with Apache Cordova and Phonegap
Apps with Apache Cordova and Phonegap
 
Apache Cordova
Apache CordovaApache Cordova
Apache Cordova
 
Phonegap/Cordova vs Native Application
Phonegap/Cordova vs Native ApplicationPhonegap/Cordova vs Native Application
Phonegap/Cordova vs Native Application
 
Cordova / PhoneGap, mobile apps development with HTML5/JS/CSS
Cordova / PhoneGap, mobile apps development with HTML5/JS/CSSCordova / PhoneGap, mobile apps development with HTML5/JS/CSS
Cordova / PhoneGap, mobile apps development with HTML5/JS/CSS
 
Cordova and PhoneGap Insights
Cordova and PhoneGap InsightsCordova and PhoneGap Insights
Cordova and PhoneGap Insights
 
Cordova: APIs and instruments
Cordova: APIs and instrumentsCordova: APIs and instruments
Cordova: APIs and instruments
 
All About Phonegap
All About Phonegap All About Phonegap
All About Phonegap
 
Introduction to jQuery Mobile
Introduction to jQuery MobileIntroduction to jQuery Mobile
Introduction to jQuery Mobile
 
Hybrid App Development with PhoneGap
Hybrid App Development with PhoneGapHybrid App Development with PhoneGap
Hybrid App Development with PhoneGap
 
Phone gap
Phone gapPhone gap
Phone gap
 
[2015/2016] Apache Cordova
[2015/2016] Apache Cordova[2015/2016] Apache Cordova
[2015/2016] Apache Cordova
 
JBoss Data Virtualization (JDV) Sample Physical Deployment Architecture
JBoss Data Virtualization (JDV) Sample Physical Deployment ArchitectureJBoss Data Virtualization (JDV) Sample Physical Deployment Architecture
JBoss Data Virtualization (JDV) Sample Physical Deployment Architecture
 
Linux container & docker
Linux container & dockerLinux container & docker
Linux container & docker
 
Agile & SCRUM
Agile & SCRUMAgile & SCRUM
Agile & SCRUM
 
IBM WebSphere Application Server (Clustering) Concept
IBM WebSphere Application Server (Clustering) ConceptIBM WebSphere Application Server (Clustering) Concept
IBM WebSphere Application Server (Clustering) Concept
 
RESTful web service with JBoss Fuse
RESTful web service with JBoss FuseRESTful web service with JBoss Fuse
RESTful web service with JBoss Fuse
 
PMP Training - 12 project procurement management
PMP Training - 12 project procurement managementPMP Training - 12 project procurement management
PMP Training - 12 project procurement management
 
PMP Training - 08 project quality management
PMP Training - 08 project quality managementPMP Training - 08 project quality management
PMP Training - 08 project quality management
 
PMP Training - 04 project integration management
PMP Training - 04 project integration managementPMP Training - 04 project integration management
PMP Training - 04 project integration management
 
PMP Training - 06 project time management2
PMP Training - 06 project time management2PMP Training - 06 project time management2
PMP Training - 06 project time management2
 

Similar to Introduction to Apache Cordova (Phonegap)

[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache Cordova
[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache Cordova[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache Cordova
[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache CordovaHazem Saleh
 
[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache Cordova
[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache Cordova[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache Cordova
[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache CordovaHazem Saleh
 
Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014
Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014
Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014Hazem Saleh
 
Apache Cordova In Action
Apache Cordova In ActionApache Cordova In Action
Apache Cordova In ActionHazem Saleh
 
[Devoxx Morocco 2015] Apache Cordova In Action
[Devoxx Morocco 2015] Apache Cordova In Action[Devoxx Morocco 2015] Apache Cordova In Action
[Devoxx Morocco 2015] Apache Cordova In ActionHazem Saleh
 
WebAPIs & Apps - Mozilla London
WebAPIs & Apps - Mozilla LondonWebAPIs & Apps - Mozilla London
WebAPIs & Apps - Mozilla LondonRobert Nyman
 
Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
 	Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W... 	Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...Robert Nyman
 
Android App Development using HTML5 Technology
Android App Development using HTML5 TechnologyAndroid App Development using HTML5 Technology
Android App Development using HTML5 TechnologyOon Arfiandwi
 
Web APIs & Apps - Mozilla
Web APIs & Apps - MozillaWeb APIs & Apps - Mozilla
Web APIs & Apps - MozillaRobert Nyman
 
Phone Gap
Phone GapPhone Gap
Phone GapYiguang Hu
 
Introduction phonegap
Introduction phonegapIntroduction phonegap
Introduction phonegapRakesh Jha
 
Advanced programing in phonegap
Advanced programing in phonegapAdvanced programing in phonegap
Advanced programing in phonegapRakesh Jha
 
Phonegap android
Phonegap androidPhonegap android
Phonegap androidumesh patil
 
Reaching out from ADF Mobile (ODTUG KScope 2014)
Reaching out from ADF Mobile (ODTUG KScope 2014)Reaching out from ADF Mobile (ODTUG KScope 2014)
Reaching out from ADF Mobile (ODTUG KScope 2014)Luc Bors
 
phonegap with angular js for freshers
phonegap with angular js for freshers    phonegap with angular js for freshers
phonegap with angular js for freshers dssprakash
 
Hybrid application development
Hybrid application developmentHybrid application development
Hybrid application developmentEngin Hatay
 
Creating and Distributing Mobile Web Applications with PhoneGap
Creating and Distributing Mobile Web Applications with PhoneGapCreating and Distributing Mobile Web Applications with PhoneGap
Creating and Distributing Mobile Web Applications with PhoneGapJames Pearce
 
NodeJS
NodeJSNodeJS
NodeJSAlok Guha
 
Mozilla, Firefox OS and the Open Web
Mozilla, Firefox OS and the Open WebMozilla, Firefox OS and the Open Web
Mozilla, Firefox OS and the Open WebRobert Nyman
 

Similar to Introduction to Apache Cordova (Phonegap) (20)

[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache Cordova
[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache Cordova[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache Cordova
[JMaghreb 2014] Developing JavaScript Mobile Apps Using Apache Cordova
 
[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache Cordova
[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache Cordova[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache Cordova
[JavaLand 2015] Developing JavaScript Mobile Apps Using Apache Cordova
 
Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014
Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014
Developing Native Mobile Apps Using JavaScript, ApacheCon NA 2014
 
Apache Cordova In Action
Apache Cordova In ActionApache Cordova In Action
Apache Cordova In Action
 
[Devoxx Morocco 2015] Apache Cordova In Action
[Devoxx Morocco 2015] Apache Cordova In Action[Devoxx Morocco 2015] Apache Cordova In Action
[Devoxx Morocco 2015] Apache Cordova In Action
 
WebAPIs & Apps - Mozilla London
WebAPIs & Apps - Mozilla LondonWebAPIs & Apps - Mozilla London
WebAPIs & Apps - Mozilla London
 
Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
 	Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W... 	Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
Bringing the open web and APIs to mobile devices with Firefox OS - Whisky W...
 
Android App Development using HTML5 Technology
Android App Development using HTML5 TechnologyAndroid App Development using HTML5 Technology
Android App Development using HTML5 Technology
 
Web APIs & Apps - Mozilla
Web APIs & Apps - MozillaWeb APIs & Apps - Mozilla
Web APIs & Apps - Mozilla
 
Phone Gap
Phone GapPhone Gap
Phone Gap
 
Introduction phonegap
Introduction phonegapIntroduction phonegap
Introduction phonegap
 
Advanced programing in phonegap
Advanced programing in phonegapAdvanced programing in phonegap
Advanced programing in phonegap
 
Phonegap android
Phonegap androidPhonegap android
Phonegap android
 
Reaching out from ADF Mobile (ODTUG KScope 2014)
Reaching out from ADF Mobile (ODTUG KScope 2014)Reaching out from ADF Mobile (ODTUG KScope 2014)
Reaching out from ADF Mobile (ODTUG KScope 2014)
 
phonegap with angular js for freshers
phonegap with angular js for freshers    phonegap with angular js for freshers
phonegap with angular js for freshers
 
Hybrid application development
Hybrid application developmentHybrid application development
Hybrid application development
 
Creating and Distributing Mobile Web Applications with PhoneGap
Creating and Distributing Mobile Web Applications with PhoneGapCreating and Distributing Mobile Web Applications with PhoneGap
Creating and Distributing Mobile Web Applications with PhoneGap
 
NodeJS
NodeJSNodeJS
NodeJS
 
Mozilla, Firefox OS and the Open Web
Mozilla, Firefox OS and the Open WebMozilla, Firefox OS and the Open Web
Mozilla, Firefox OS and the Open Web
 
iOS App Using cordova
iOS App Using cordovaiOS App Using cordova
iOS App Using cordova
 

More from ejlp12

Introduction to Docker storage, volume and image
Introduction to Docker storage, volume and imageIntroduction to Docker storage, volume and image
Introduction to Docker storage, volume and imageejlp12
 
Java troubleshooting thread dump
Java troubleshooting thread dumpJava troubleshooting thread dump
Java troubleshooting thread dumpejlp12
 
WebSphere Application Server Information Resources
WebSphere Application Server Information ResourcesWebSphere Application Server Information Resources
WebSphere Application Server Information Resourcesejlp12
 
WebSphere Application Server Family (Editions Comparison)
WebSphere Application Server Family (Editions Comparison)WebSphere Application Server Family (Editions Comparison)
WebSphere Application Server Family (Editions Comparison)ejlp12
 
BPEL, BPEL vs ESB (Integration)
BPEL, BPEL vs ESB (Integration)BPEL, BPEL vs ESB (Integration)
BPEL, BPEL vs ESB (Integration)ejlp12
 
BPMN Introduction
BPMN IntroductionBPMN Introduction
BPMN Introductionejlp12
 
WebSphere Application Server Topology Options
WebSphere Application Server Topology OptionsWebSphere Application Server Topology Options
WebSphere Application Server Topology Optionsejlp12
 
IBM WebSphere Application Server version to version comparison
IBM WebSphere Application Server version to version comparisonIBM WebSphere Application Server version to version comparison
IBM WebSphere Application Server version to version comparisonejlp12
 
IBM WebSphere MQ Introduction
IBM WebSphere MQ Introduction IBM WebSphere MQ Introduction
IBM WebSphere MQ Introduction ejlp12
 
Java EE Introduction
Java EE IntroductionJava EE Introduction
Java EE Introductionejlp12
 
Introduction to JPA (JPA version 2.0)
Introduction to JPA (JPA version 2.0)Introduction to JPA (JPA version 2.0)
Introduction to JPA (JPA version 2.0)ejlp12
 
Introduction to JavaBeans Activation Framework v1.1
Introduction to JavaBeans Activation Framework v1.1Introduction to JavaBeans Activation Framework v1.1
Introduction to JavaBeans Activation Framework v1.1ejlp12
 
Arah pengembangan core network architecture (Indonesia)
Arah pengembangan core network architecture (Indonesia)Arah pengembangan core network architecture (Indonesia)
Arah pengembangan core network architecture (Indonesia)ejlp12
 
GSM/UMTS network architecture tutorial (Indonesia)
GSM/UMTS network architecture tutorial (Indonesia)GSM/UMTS network architecture tutorial (Indonesia)
GSM/UMTS network architecture tutorial (Indonesia)ejlp12
 
PMP Training - 11 project risk management
PMP Training - 11 project risk managementPMP Training - 11 project risk management
PMP Training - 11 project risk managementejlp12
 
PMP Training - 10 project communication management
PMP Training - 10 project communication managementPMP Training - 10 project communication management
PMP Training - 10 project communication managementejlp12
 
PMP Training - 09 project human resource management
PMP Training - 09 project human resource managementPMP Training - 09 project human resource management
PMP Training - 09 project human resource managementejlp12
 
PMP Training - 07 project cost management
PMP Training - 07 project cost managementPMP Training - 07 project cost management
PMP Training - 07 project cost managementejlp12
 
PMP Training - 05 project scope management
PMP Training - 05 project scope managementPMP Training - 05 project scope management
PMP Training - 05 project scope managementejlp12
 
PMP Training - 01 introduction to framework
PMP Training - 01 introduction to frameworkPMP Training - 01 introduction to framework
PMP Training - 01 introduction to frameworkejlp12
 

More from ejlp12 (20)

Introduction to Docker storage, volume and image
Introduction to Docker storage, volume and imageIntroduction to Docker storage, volume and image
Introduction to Docker storage, volume and image
 
Java troubleshooting thread dump
Java troubleshooting thread dumpJava troubleshooting thread dump
Java troubleshooting thread dump
 
WebSphere Application Server Information Resources
WebSphere Application Server Information ResourcesWebSphere Application Server Information Resources
WebSphere Application Server Information Resources
 
WebSphere Application Server Family (Editions Comparison)
WebSphere Application Server Family (Editions Comparison)WebSphere Application Server Family (Editions Comparison)
WebSphere Application Server Family (Editions Comparison)
 
BPEL, BPEL vs ESB (Integration)
BPEL, BPEL vs ESB (Integration)BPEL, BPEL vs ESB (Integration)
BPEL, BPEL vs ESB (Integration)
 
BPMN Introduction
BPMN IntroductionBPMN Introduction
BPMN Introduction
 
WebSphere Application Server Topology Options
WebSphere Application Server Topology OptionsWebSphere Application Server Topology Options
WebSphere Application Server Topology Options
 
IBM WebSphere Application Server version to version comparison
IBM WebSphere Application Server version to version comparisonIBM WebSphere Application Server version to version comparison
IBM WebSphere Application Server version to version comparison
 
IBM WebSphere MQ Introduction
IBM WebSphere MQ Introduction IBM WebSphere MQ Introduction
IBM WebSphere MQ Introduction
 
Java EE Introduction
Java EE IntroductionJava EE Introduction
Java EE Introduction
 
Introduction to JPA (JPA version 2.0)
Introduction to JPA (JPA version 2.0)Introduction to JPA (JPA version 2.0)
Introduction to JPA (JPA version 2.0)
 
Introduction to JavaBeans Activation Framework v1.1
Introduction to JavaBeans Activation Framework v1.1Introduction to JavaBeans Activation Framework v1.1
Introduction to JavaBeans Activation Framework v1.1
 
Arah pengembangan core network architecture (Indonesia)
Arah pengembangan core network architecture (Indonesia)Arah pengembangan core network architecture (Indonesia)
Arah pengembangan core network architecture (Indonesia)
 
GSM/UMTS network architecture tutorial (Indonesia)
GSM/UMTS network architecture tutorial (Indonesia)GSM/UMTS network architecture tutorial (Indonesia)
GSM/UMTS network architecture tutorial (Indonesia)
 
PMP Training - 11 project risk management
PMP Training - 11 project risk managementPMP Training - 11 project risk management
PMP Training - 11 project risk management
 
PMP Training - 10 project communication management
PMP Training - 10 project communication managementPMP Training - 10 project communication management
PMP Training - 10 project communication management
 
PMP Training - 09 project human resource management
PMP Training - 09 project human resource managementPMP Training - 09 project human resource management
PMP Training - 09 project human resource management
 
PMP Training - 07 project cost management
PMP Training - 07 project cost managementPMP Training - 07 project cost management
PMP Training - 07 project cost management
 
PMP Training - 05 project scope management
PMP Training - 05 project scope managementPMP Training - 05 project scope management
PMP Training - 05 project scope management
 
PMP Training - 01 introduction to framework
PMP Training - 01 introduction to frameworkPMP Training - 01 introduction to framework
PMP Training - 01 introduction to framework
 

Recently uploaded

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clashcharlottematthew16
 

Recently uploaded (20)

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort ServiceHot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clash
 

Introduction to Apache Cordova (Phonegap)

  • 1. Introduction to ejlp12@gmail.com
  • 2. Apache Cordova Apache Cordova is a platform for building natively installed mobile applications using HTML, CSS and JavaScript
  • 3. History Apache Cordova was originally called Phonegap build by Nitobi Open-source & free software from the beginning (MIT License), Apache License now Nitobi then aquired by Adobe and donated the PhoneGap codebase to the Apache Software Foundation (ASF) PhoneGap is still a product of Adobe. It is a distribution of Apache Cordova. Think of Apache Cordova as the engine that powers PhoneGap.
  • 5. Apache Cordova Application’s User Interface The user interface for Apache Cordova applications is created using HTML, CSS, and JavaScript. The UI layer is a web browser view that takes up 100% of the device width and 100% of the device height. The web view used by application is the same web view used by the native operating system iOS: Objective-C UIWebView class Android: android.webkit.WebView WP7: WebBrowser WP8: WebBrowser control (Internet Explorer 10) BlackBerry: WebWorks framework
  • 6. Apache Cordova API Provides an application programming interface (API) enables you to access native operating system functionality using JavaScript. APIs for Accelerometer, Camera, Compass, Media, FileSystem, etc Extendable using native plug-in docs.phonegap.com Cordova JavaScript API Cordova Application and Native API Cordova Native Library
  • 7. Supported Platforms Accelerometer Monitor the motion sensor on the device. Camera Take pictures with the device camera allow the user to select images from their photo library on the device. Capture Capture video and still images from the camera, and audio from the microphone. Compass Give users of your app some direction. Contacts Search and Create contacts in the user’s address book. File Low level read and write access to the file system. Upload and download files from a web server. GeoLocation Make your app location aware. Media Play and record audio files. Network Monitor the device connections Notification Access to vibration, beep and alerts. Storage Updated list: Persistent data store in WebStorage. http://wiki.apache.org/cordova/PlatformSupport
  • 8. Development using Cordova Tools for development Any HTML & JS editor Platform SDK e.g. Android SDT, Android SDK, BB SDK, Xcode, Visual Studio Mobile. Platform Emulator (usually provide along with SDK) JS/HTML GUI Mobile framework e.g. JQuery, Sencha Touch, dojo Mobile Browser e.g. Firefox with Bugzilla extension, Chrome Browser
  • 9. Getting Started Guides: • Getting Started with Android • Getting Started with Blackberry • Getting Started with iOS • Getting Started with Symbian • Getting Started with WebOS • Getting Started with Windows Phone • Getting Started with Windows 8 • Getting Started with Bada • Getting Started with Tizen http://docs.phonegap.com/en/2.2.0/guide_getting-started_index.md.html Use platform SDK to develop application for each target platform … Xcode Android SDK BB Java Eclipse Plug-in Visual Studio, Windows Eclipse ADT Plug-in Ripple Phone Dev Tools
  • 10. Code Example <!DOCTYPE html> <html> <head> <title>Device Properties Example</title> <script type="text/javascript" charset="utf-8" src="cordova-2.0.0.js"></script> <script type="text/javascript" charset="utf-8"> // Wait for Cordova to load document.addEventListener("deviceready", onDeviceReady, false); // Cordova is ready function onDeviceReady() { navigator.geolocation.getCurrentPosition(onSuccess, onError); } // onSuccess Geolocation function onSuccess(position) { var element = document.getElementById('geolocation'); element.innerHTML = 'Latitude: ' + position.coords.latitude + '<br />' + 'Longitude: ' + position.coords.longitude + '<br />' + 'Altitude: ' + position.coords.altitude + '<br />' + 'Accuracy: ' + position.coords.accuracy + '<br />' + 'Altitude Accuracy: ' + position.coords.altitudeAccuracy + '<br />' + } // onError Callback receives a PositionError object function onError(error) { alert('code: ' + error.code + 'n' + message: ' + error.message + 'n'); } </script> </head> <body> <p id="geolocation">Finding geolocation...</p> </body> </html>
  • 11. Apache Cordova Native Plug-in What if a native feature isn’t available in Core APIs? PhoneGap is extensible with a “native plugin” model that enables you to write your own native logic to access via JavaScript. You develop your JavaScript class to mirror the API of the native class Invoke the native function using PhoneGap.exec() Plug-in class mappings: Android: res/xml/plugins.xml iOS: www/Cordova.plist BlackBerry: www/plugins.xml PhoneGap.exec(function(winParam){}, function(error){}, ”service”, ”action", [params]);
  • 12. Plugin Example (Android Native Code) package sample.cordova.plugin; import org.apache.cordova.api.CordovaPlugin; import org.apache.cordova.api.PluginResult; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; /** * This class echoes a string called from JavaScript. Extend the Cordova Implement execute */ Plugin class method public class Echo extends CordovaPlugin { @Override public boolean execute(String action, JSONArray args, CallbackContext callbackContext) throws JSONException { Define and handle if (action.equals("echo")) { action String message = args.getString(0); if (message != null && message.length() > 0) { callbackContext.success(message); } else { callbackContext.error("Expected one non-empty string argument."); } return true; } return false; } }
  • 13. Plugin Example (HTML + JS Code) <!DOCTYPE html> <html> <head> <title>Cordova Plugin Test</title> <script type="text/javascript" charset="utf-8" src="cordova-2.0.0.js"></script> <script type="text/javascript" charset="utf-8"> var EchoPlugin = { callNativeFunction: function (success, fail, resultType) { return Cordova.exec( success, fail, “sample.cordova.plugin.Echo", "echo", [resultType]); } }; function callNativePlugin( returnSuccess ) { HelloPlugin.callNativeFunction( nativePluginResultHandler, nativePluginErrorHandler, returnSuccess ); } function nativePluginResultHandler (result) { alert("SUCCESS: rn"+result ); } function nativePluginErrorHandler (error) { alert("ERROR: rn"+error ); } </script> </head> <body> <body onload="onBodyLoad()"> <h1>Cordova Plugin Test</h1> <button onclick="callNativePlugin('success');">Click to invoke the Native Plugin!</button> </body>
  • 14. Resources Apache Cordova Website http://cordova.apache.org/ Apache Cordova Documentation http://docs.phonegap.com/en/2.2.0/index.html PhoneGap Day 2011 – IBM, PhoneGap and the Enterprise by Bryce Curtis [Aug 10, 2011] http://www.slideshare.net/drbac/phonegap-day-ibm-phonegap-and-the-enterprise (video) Andrew Trice’s Blog http://www.tricedesigns.com/category/cordova/

Editor's Notes

  1. Think of this as a “headless” web browser.  It renders HTML content, without the “chrome” or window decoration of a regular web browser.  You build your application to take advantage of this space, and you build navigational/interactive/content elements and application chrome into your HTML and CSS based user interface.-- https://github.com/mrlacey/phonegap-wp7/blob/master/framework/PhoneGap/NativeExecution.cs
  2. In addition to the “out of the box” functionality, you can also leverage PhoneGap’s JavaScript-to-native communication mechanism to write “native plugins”. PhoneGap native plugins enable you to write your own custom native classes and corresponding JavaScript interfaces for use within your PhoneGap applications.You build your application logic using JavaScript, and the PhoneGap API handles communication with the native operating system.If you need to access native functionality that isn’t already exposed, then you can easily create a native plugin to provide access to that native functionality.PhoneGap native plugins shouldn’t be thought of as “plugins” like Flash Player inside of a browser, rather you are “plugging in” additional functionality that extends the core PhoneGap framework.
  3. SDK for Windows Phone 7.0, 7.5 and 8.0 - https://dev.windowsphone.com/en-us/downloadsdkThe Windows Phone Software Development Kit (SDK) 8.0 provides you with the tools that you need to develop apps and games for Windows Phone 8 and Windows Phone 7.5.Visual StudioWindows Phone 8 EmulatorWindows Phone Application AnalysisSimulation DashboardStore Test Kit.The Windows Phone Software Development Kit (SDK) 7.1 provides you with all of the tools that you need to develop applications and games for both Windows Phone 7.0 and Windows Phone 7.5 devices.Microsoft Visual Studio 2010 Express for Windows PhoneWindows Phone EmulatorWindows Phone SDK 7.1 AssembliesSilverlight 4 SDK and DRTWindows Phone SDK 7.1 Extensions for XNA Game Studio 4.0Microsoft Expression Blend SDK for Windows Phone 7Microsoft Expression Blend SDK for Windows Phone OS 7.1WCF Data Services Client for Window PhoneMicrosoft Advertising SDK for Windows PhoneWindows Mobile 6, 6.5 - http://msdn.microsoft.com/en-us/windowsmobile/defaultStudio 2005 or 2008The Windows Mobile 6 SDK Refresh adds documentation, sample code, header and library files, emulator images and tools to Visual Studio that let you build applications for Windows Mobile 6.The Windows Mobile 6.5.3 DTK provides documentation, sample code, header and library files, emulator images and tools you can use with Visual Studio to build applications for Windows Mobile 6.5 and 6.5.3.
  4. function(winParam) {} - Success function callback. Assuming your exec call completes successfully, this function will be invoked (optionally with any parameters you pass back to it)function(error) {} - Error function callback. If the operation does not complete successfully, this function will be invoked (optionally with an error parameter)&quot;service&quot; - The service name to call into on the native side. This will be mapped to a native class. More on this in the native guides below&quot;action&quot; - The action name to call into. This is picked up by the native class receiving the exec call, and, depending on the platform, essentially maps to a class&apos;s method. [/* arguments */] - Arguments to get passed into the native environment