I have heard that there are soft wares for converting an existing J2ME app to Android? But I was doing a manual conversion till now. Am I doing a silly job/is it possible to do convert any J2ME application?

link|improve this question
feedback

3 Answers

up vote 5 down vote accepted

I don't know about such software, but believe me you'll get the best if you port it manually. In the end, you want your app to be a success, don't you? That means high user satisfaction. Automatic converters cannot do that, at least I've not seen any that produces good and mainly also afterwards maintainable apps.

link|improve this answer
1  
I agree. As both are Java based, it will be less a daunting task. – SidCool Mar 9 '11 at 17:34
1  
Automatic converters are probably a good way to start but there will probably be a lot of manual tweaking and adjusting afterwards. – FrustratedWithFormsDesigner Mar 9 '11 at 19:27
@FrustratedWithFormsDesigner Indeed. But I guess the tweaking and adjusting gets more complicated as those tools normally create code that is easy to generate rather than understandable by a human. So since both worlds use Java, manual porting is probably way easier :) – Juri Mar 9 '11 at 19:29
1  
+1 As the Lone Ranger said to Tonto after a long day of crime fighting: "There are no silver bullets." – Gary Rowe Mar 9 '11 at 21:46
feedback

I agree with the previous answer that porting your code to native Android is probably your best choice in the long run. Primarily for getting an Android-like user experience but also to take advantage of the more advanced possibilities of the platform. (But be aware that it's not that easy just because both J2ME and Android are phone platforms based on Java. It is a completely different platform.)

If you, despite this, is set on just running your existing J2ME application on Android, one viable alternative is running a J2ME emulator inside of Android. This is how Opera Mini was run on Android, originally. (Maybe it still is, for all I know.)

It sounds difficult, but check out this article on how easy it really is to do this with MicroEmu:

http://microemu.blogspot.com/2009/08/converting-javame-applications-to.html

For the record, I have no affiliation with MicroEmu what so ever. :-)

link|improve this answer
sounds good.... – newcomer Nov 27 '11 at 5:40
feedback

newcomer,

I've been looking at a similar problem myself and I'm in the process of porting one of my own applications to BlackBerry and Android. In my case, I have a discrete domain layer, so it was easy to plug into other technologies. The only thing required was to wire in the UI and network/infrastructure layers. This worked out well because I could unit test the domain layer without having to start up a simulator, which is a common problem faced in mobile application development. As a bonus, it's Java to Java, so It'll be even easier for you.

Once you've done your port and if you don't have a discrete domain layer, I'd look into refactoring you code to have one in place so that porting becomes easier. Even if it's for another language, technology, all the business logic is in the one place and you don't need to filter through XML parsing, network communication code etc. As a plug, I'd recommend reading Eric Evan's Domain Driven Design. I believe this kind of approach is even more important in mobile development when your porting your app to different platforms. The domain model might not be as rich on the mobile app as you've got limited memory, so some compromises may have to be made, but it's definitely worth aiming for to make the problem you've describe a minor issue.

link|improve this answer
thanks for sharing – newcomer Nov 27 '11 at 5:40
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.