Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Posts: 1
Registered: ‎01-30-2011
My Device: Not Specified
Accepted Solution

Questions on JavaScript Extension, and SQLite

Hi All,


I have been working with some my colleague on projects related to WebWorks application, but there are some technical concerns which our developers really wish to know and ask for some professional advice.


1) JavaScript Extension & PlayBook


According to the documentation, we know that BlackBerry WebWorks Application have the ability to integrate with the data, features and capabilities from the underlying Java® development environment as well as the native BlackBerry® Smartphone through the use of special JavaScript® objects (JavaScript Extension). Therefore, we should be able to create some Java® Libraries (JAR) and program the WebWorks Application to call BlackBerry Java API inside the libraries. Now we know that BlackBerry® PlayBook provide a WebWorks SDK (Beta) for us to develop WebWorks Application for PlayBook, does it also mean that in PlayBook enviroment we can also use the JavaScript Extension trick to call those BlackBerry Java API ?


2) SQLite on HTML5


HTML5 provides SQLite standard to let us store data in a SQLite database format. But the SQLite file seems only restricted to be used within the WebWorks Application. I wonder if there are any ways we can read these SQLite file from other application (Other WebWorks Application, or Java Application) ?


In fact, what I want to know is the feasibility to have a WebWorks Application that manipulate a SQLite file which is received from server side on-the-fly, then send it back the whole SQLite file to server.


It would be appreciate if some of you can give some advices on this, thank you.



Posts: 80
Registered: ‎06-26-2008
My Device: Not Specified

Re: Questions on JavaScript Extension, and SQLite

1) i didn't start to play with playbook simulator, but i the webwork extension provided are implemented with action script/adobe air, so i think, we have to program with adobe air to create our own extensions. You have to know that playbook has not a java vm yet.


2)I think the answer is no. Webwork apps use sqlite encrypted files, so only webworks application could access to the database.



Posts: 3,708
Registered: ‎10-16-2008
My Device: Z10
My Carrier: Rogers

Re: Questions on JavaScript Extension, and SQLite

lasterra is correct on both points...


We have not yet released details on creating extensions in AIR for WebWorks on PlayBook. We are currently working on putting the final open source touches on the WebWorks for PlayBook SDK so that we can upload it to github.  The full source code to the platform will be available on github so that you can see everything that is going on under the hood.


Creating extensions in AIR for WebWorks is very different than in Java. We have started using a new architecture that should be able to provide both URI and procedural access to APIs and placing more of the procedural API code into JavaScript itself vs the existing ScriptableObject Java code today.  


This new architecture will be a preview of the WebWorks platform architecture moving forward.


Details on creating extensions in AIR will be coming.. but currently the main underlying API platform on the BlackBerry PlayBook is AIR and the functionality of an extension will be limited to what is possible on the AIR platform and its extensions.


As the PlayBook's development options evolve, so too will the architecture of the WebWorks platform... I can't really say much more than that right now Smiley Happy

Tim Neil
Director, Application Platform & Tools Product Management
Follow me on Twitter
Posts: 80
Registered: ‎06-26-2008
My Device: Not Specified

Re: Questions on JavaScript Extension, and SQLite

I hope that playbook team will put a java vm inside it before they put plabook on street ;-)