BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 12-02-2008, 12:49 PM   #1 (permalink)
New Member
 
Join Date: Dec 2008
Model: none
PIN: N/A
Carrier: AT&T
Posts: 6
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default Java Confusion.

Please Login to Remove!

I'm brand new to BlackBerry development and I've been doing some reading, but until I clear these few things up I find that my preconceptions are confusing me.

I know BlackBerry has it's own OS, but I've read that it uses Java (the language) to write applications which interface with Java ME (the framework). Is Java ME the same framework that is used to manipulate contacts, photos, etc on the device? Or will I need to access native APIs for that via a different mechanism?

My preconception is that Java ME is a framework running on top of BlackBerrys native OS and thus applications will be a mixture of native API calls (if you want to get contacts) and regular Java (to do less device specific things). As such, applications developed in this way for BlackBerry will only have portability to other Java based devices (like Android) in the sense that any non-device specific code can be moved over fairly easily.

Am I wrong?

Thanks in advance to anyone reading this.
Offline  
Old 12-02-2008, 01:19 PM   #2 (permalink)
BlackBerry Extraordinaire
 
Join Date: Jan 2006
Model: LEZ10
OS: 10.0.10
Carrier: Rogers CA
Posts: 1,704
Post Thanks: 20
Thanked 77 Times in 68 Posts
Default

Yes, a bit. The Blackberry specific APIs are written in Java as extensions to Java ME. Any application you write will be all Java. You can write and run pure J2ME applications on Blackberries, but to make full use of the platform features you will need to access the specific APIs.
Offline  
Old 12-02-2008, 03:46 PM   #3 (permalink)
New Member
 
Join Date: Dec 2008
Model: none
PIN: N/A
Carrier: AT&T
Posts: 6
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

So I guess I wasn't too far off. Thanks for your reply.

Does the J2ME framework provide ANY form of interface into device specific functions like getting contacts, or is that entirely handled by the Blackberry API?

I'm inquiring as to the extent of the framework as it seems to me that it wouldn't be so hard to provide certain common functions into the actual framework that could be platform independent -- like fetching contacts. To confirm, you are saying that things of this nature are totally handled by the BlackBerry API (which doesn't go trough the J2ME framework)?

Thanks again.
Offline  
Old 12-02-2008, 06:48 PM   #4 (permalink)
BlackBerry Extraordinaire
 
Join Date: Mar 2008
Location: Austin, TX
Model: 9700
PIN: N/A
Carrier: T-Mobile
Posts: 1,644
Post Thanks: 0
Thanked 34 Times in 33 Posts
Default

The Contacts come under the PIM database, which is accessed (mostly) via JSR75. BlackBerry has their own "extension" to JSR75, but you are free to ignore this and use the standard. You just will not have access to the BlackBerry-specific extensions.

You ask the question "...which doesn't go through the J2ME framework" - it is important to note that the BlackBeryy API's are built on the J2ME framework, so there is really no way to separate them. Think of the BlackBerry API as a layer on top of J2ME.

You can have J2ME without BlackBerry, but not vice-versa.
Offline  
Old 12-02-2008, 07:34 PM   #5 (permalink)
New Member
 
Join Date: Dec 2008
Model: none
PIN: N/A
Carrier: AT&T
Posts: 6
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks. That explains a lot.
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Copyright 2004-2014 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.