views:

198

answers:

4

We got a new mobile application. I am confused in which language I prefer. i want to know the exact reason.?

+3  A: 

As far as I know and I have had very limited experience so maybe if someone can expand on my comments. C++ means you need Symbian. It is more difficulty, you need to handle your own memory. The documentation is scant and there is a small community. Few phones have Symbian. Java needs J2ME. More phones have Java installed compared to Symbian. Documentation is pretty good and there is a good community. I have only had experience in Java. Java also has garbage collection for people like me.

uriDium
Symbian Supports java?
Vibin Jith
Maybe it does. But I am not a mobile developer by trade so you would have to check it out.
uriDium
@Vibin, yes actually most Nokia and SE mobiles applications are Java
medopal
Symbian is not the only mobile platform to support apps in C++, although it is probably the easiest for third-party app developers to get onto. That is, of course, if you discount the iPhone (which it's difficult to write *purely* in C++ for, but you can do so substantially)
Phil Nash
+1  A: 

I suspect you'll be able to target a broader range of phones using Java (targeting J2ME, Android, Blackberry, and such) than using C++. Another option is to use one of the .Net languages targeting Windows Mobile and Windows CE, but of course that means the app only runs on Windows mobiles, which are still a minority of the market. Or you could use Objective-C and develop for the iPhone, but despite all the hype it too has a minority of the market.

Depending on your application, another choice is to develop your application as a web app optimised for mobile devices. That opens up the range considerably, as nearly all smart phones have reasonable mini-browsers now. It also opens up your language choices to just about anything you want, although for client-side behaviors it'll have to be JavaScript.

This article on smart phone trends may be useful in helping you choose. Sadly this is an area where your target market largely dictates your development tool choices.

T.J. Crowder
A: 

Depends on your audience and your platform of choice.

The whole world is moving towards smartphones. i.e. iPhone, Android and BlackBerry. To make a really popular you should make mainly two versions (at least), one for iPhone (using ObjectiveC) and another for Android (using Java)

medopal
heh, one of the major reasons, of using a higher leval language (esp java with it's virtual machine) is so that it can be platform indepenant. surly someone has writtem a java VM for Iphone by now?
Oxinabox
till the iPhone is not jailbroken no one can make a VM for it, and for sure Apple is not interested
medopal
+1  A: 

Java is typically easier to write and easier to get right (not just because of the garbage collection, but that's certainly a big factor). From a developer productivity perspective it is likely to be more "effective". However on a mobile device you have memory and processing constraints that mean the runtime differences between C++ and Java are often going to be noticible. Not that you always have a choice - some platforms dictate one way or another. The iPhone, for example, doesn't allow Java at all - although you can use C# (via Monotouch). Although everyone talks about Objective-C on the iPhone, and you do need to use it for at least the GUI, you can write C++ for it just fine.

Apple's use of Objective-C on the iPhone is telling. The iPhone is quite a capable device by mobile device standards, and yet Apple chose to disable garbage collection in Objective-C for iPhone, even though it is available in the desktop version. Apparently this is for efficiency reasons (although I don't believe Apple has said this outright - anyone know differently?).

Only a few years ago I worked for a provider of mobile platform components (browser, messaging, app framework) and they had only recent ported their code-base from C to C++ (much of it was still esentially C), and most of the handset vendors I worked with where still very much C focused (some had their own OO extensions to C). Although this was partly due to momentum and less compiler support early on, there was also a common feeling that even C++ was not efficient enough for such devices!

Phil Nash