Showing posts with label Java ME. Show all posts
Showing posts with label Java ME. Show all posts

11.10.2011

J2ME at the Brink of Extinction

I realized that the growing number of smart phones on the market is heavily tearing down the marketability of JME (or J2ME) apps. JME has been around for about a decade and might be nearing its end with the rise of platforms like the Android, iOS, and Windows mobile.

Since in my line of work I have to deal with JME applications, I see that there are those who prefer JME apps over Android or iOS apps. One reason is that not everyone (or every country) is up to date with the latest mobile technologies, most especially with mobile phones. For example, a phone that was phased out by Nokia six years ago is possibly the widely used or sold phone by a telecom company in a third world country.

Oracle announced that they will modernize JME. But until the product is made available to the public, JME is a dying technology.

Although this (JME use is declining) is the trend that I see, perhaps I will still use JME for a long time. Or maybe a year or two. Right now I find JME apps development very exciting. There are tons of technologies related to JME that I haven't explored yet. Maybe by the time I fully set aside JME development there are still plenty to be learned. Right now I am just thankful to be able to work on JME apps. However, learning new skills on Android or iOS development would pretty much add more to my understanding on mobile technologies.

5.21.2010

Debug Your JME App

Findbugs™ is one really super cool tool for Java developers. It does excellent in locating errors in the source code especially those that are not obvious to the programmer's eye. One interesting thing is that it can also analyze Java applications for MIDP devices.

Here's a simple how-to-use for you if you want to analyze your JME project.

1. Download the Findbugs™ application.
2. Extract the contents of the zip file to any directory.
3. Go to bin folder and execute findbugs.bat.
4. To start a new analysis select File > New Project.
5. Write a name on the Project name field.
6. (I suppose you already have the jar file of your project at this point.) On Class archives and directories to analyze, click Add and then select the jar file to be analyzed. Make sure that the target jar was built without any obfuscation.
7. For Auxillary class locations, select Add then locate the JSR jar files that were used/imported in your JME project. By default, these JSR files are bundled with NetBeans so if you are using NetBeans IDE look for them in the NetBeans intallation directory (they are located in the [NetBeans 6.8] mobility8 folder... and I'm not yet sure about Eclipse... I haven't used Eclipse for a while). If you are not sure which to add, select all of the jar files.
8. For Source directories just select the source code folder. Example, C:\Myporject\src
9. Finally, click Finish. Analysis will start immediately.

Note that not every bug that are detected in the analysis is valid. You have the option to tag its validity. Yet this tool is very effective in detecting a number of errors in your code that you failed to notice maybe because of the structure of the code, or its complexity, or maybe because of your style of coding.