Worklight Phone Gap Android application

I just created my first Worklight Phone Gap application for Android. The process is pretty easy you just add support for Android environment and then WorkLight creates/generates Android project for you. Once your project is ready you just right click on it and say Run as Android application to get a view like this
I wanted to see what is going on so i looked at the generated project, but before that this is how my Worklight application is structured
When you add support for Android, WorkLight generates PhoneGap Android project that is similar to Getting Started with PhoneGap on Android project, the Generated Java class looks like this

package com.HelloWorkLightPhoneGap;

import android.os.Bundle;

import com.worklight.androidgap.WLDroidGap;

public class HelloWorkLightPhoneGap extends WLDroidGap {
 @Override
 public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    super.loadUrl(getWebMainFilePath());
 }  
}
So basically this class is forwarding control to the HTML page but the HTML file name is not hard coded here instead it comes from wlclient.properties file which looks like this

wlServerProtocol = http
wlServerHost = 192.168.94.131
wlServerPort = 8080
wlAppId = HelloWorkLightPhoneGap
wlAppVersion = 1.0
wlC2DMEmailSender = ${wlC2DMEmailSender}
wlMainFilePath = HelloWorkLightPhoneGap.html
enableSettings = true
So the HelloWorkLightGap.html file is the main file for my WorkLight application that becomes a main file here. Also if you take a closer look at the content of the project you will notice that the Android has assets/www/default folder which has all the files from your worklight application

7 comments:

Blerina said...

Could you please do a tutorial on how to implement oauth2.0 to access google api through worklight?

Anonymous said...

Thanks for sharing your knowledge like this.

I would like to invite you to try out latest iteration of "AppGyver steroids" for PhoneGap. I believe you will be able to build apps much faster for your customers than ever before.

www.AppGyver.com/steroids

Please give it a try and let me know what you think, and let me know if you have any questions; I'd be happy to introduce to to the support team.

These recent write-ups give a little more context:
http://techcrunch.com/2013/03/01/pitching-app-ideas-appgyver-delivers-mobile-app-prototypes-in-minutes-no-technical-know-how-needed/

http://venturebeat.com/2013/06/03/pitching-an-app-appgyver-says-it-can-deliver-gorgeous-prototypes-more-exclusive/

http://www.infoworld.com/d/application-development/appgyver-aims-make-phonegap-developers-more-effective-using-steroids-220102

Cheers,
Michael
www.AppGyver.com

Follow me: https://twitter.com/AnAppGyverGuy

"We will not be remembered for building cool tools that build crappy apps"

Unknown said...

Nice post and great content.
Avast Customer Support is here to help you out with the whole procedure to Download Avast Antivirus online, We not only fix your Avast Support related issues but will guide with how to get started with your new Avast product once it gets installed successfully. We at Avast Tech Support provides service to protect your PC from potential online threats and external attacks like viruses, Trojans, malwares, spywares and phishing scams. And Avast Refund. Call on our Avast Phone Number

Gmail Customer service is a third party technical support service for Gmail users when they face any technical issue or error in their Gmail account. Our Gmail Customer Support team solves issues like forgot Gmail account password, Gmail configuration or Sync issues, recover deleted emails and many more. Toll Free number (800) 986-9271

How you install or reinstall Office 365 or Office 2016 depends on whether your Office product is part of an Office for home or Office for business plan. If you're not sure what you have, see what office com setup products are included in each plan and then follow the steps for your product. The steps below also apply if you're installing a single, stand-alone Office application such as Access 2016 or Visio 2016. Need Help with office setup Enter Product Key? Call 1-800-000-0000 Toll Free
Norton Tech Support is a third party service provider and not in any way associated with Norton or any of its partner companies. We offer support for Norton products and sell subscription based additional warranty on computer and other peripheral devices. Call our Toll Free number 1 855 966 3855
Other Services
Norton Toll Free , Office-Setup , office.com/setup.

Anonymous said...

This is great! I will also share vender app it is a productivity tools that is helpful to business people

Cyanous said...

Clear cut explanation. Am pretty much impressed with your explanation. Looking for the best phone gap app development services in Hyderabad, India? Contact Cyanous software solutions now.

Best network penetration testing services in Hyderabad
Best software & web development company in Hyderabad

Saumya Dubey said...

Thank you for your post. This is excellent information. It is amazing and wonderful to visit your site. For more info:- Phonegap App Development

Quintero Soloutions said...

I think using a PhoneGap app development service, like the one you used for your Worklight project, can be a great way to quickly and easily create cross-platform mobile applications. With PhoneGap, you can write your app once using web technologies like HTML, CSS, and JavaScript, and then deploy it to multiple platforms with minimal changes.

One of the advantages of using a service like PhoneGap is that it can handle a lot of the platform-specific details for you, like generating the Android project and configuring the environment. This can save you a lot of time and effort, especially if you're new to mobile development.

Of course, there are also some potential downsides to using a service like this. For example, you may not have as much control over the final product as you would if you built everything from scratch. Additionally, if you need to implement complex features or functionality, you may run into limitations with PhoneGap's capabilities.

Overall, I think it's great that you were able to successfully create your first Worklight PhoneGap application for Android using a development service. This is a great way to get started with mobile development, and I hope you continue to learn and grow in this field.