How can one develop iPhone apps in Java?

163,519

Solution 1

If you've completed your other projects, why not take the time to learn Objective-C? There is a ton of material out on the web to help you get started. Honestly, it won't be that hard and learning to do some memory management will be a great learning exercise. Have you programmed in C before?

Most cross compilers won't do a great job in converting your code, and debugging your project may become much more difficult if you develop them this way.

Solution 2

I think we will have to wait a couple of years more to see more progress. However, there are now more frameworks and tools available:

Here a list of 5 options:

Solution 3

I think your teacher sent you down the wrong path.

This is a classic example of trying to put a square peg into a round hole. The best way to develop for the iPhone is with the iPhone SDK and objective C. The best way to develop for Andriod is Java and the Android SDK. The best way to develop for WinMobile is C#/VB and the .Net Framework.

As you can see each has their own "best" SDK. Since you are only learning Java I would second the suggestion to play around with Java and Android.

Solution 4

There is anew tool called Codename one: One SDK based on JAVA to code in WP8, Android, iOS with all extensive features

Features:

  1. Full Android environment with super fast android simulator
  2. An iPhone/iPad simulator with easy to take iPhone apps to large screen iPad in minutes.
  3. Full support for standard java debugging, profiling for apps on any platform.
  4. Easy themeing / styling – Only a click away

More at Develop Android, iOS iPhone, WP8 apps using Java

Solution 5

take a look at codenameone.com project, it's a cross platform mobile framework where the ui part is a fork of LWUIT. This project leverage xmlvm to translates the java bytes code to Objective C

Share:
163,519
Brendan Lesniak
Author by

Brendan Lesniak

Working as a Software Engineer in the Quality Management and Contact Center space. In my free time I like to work on a wide variety of projects, from Legacy Swing applications, to Web Apps, to Embedded Systems.

Updated on February 08, 2021

Comments

  • Brendan Lesniak
    Brendan Lesniak over 3 years

    I was wondering if is it possible to develop iPhone applications using Java plus XMLV, which claims to cross-compile Java-based Android applications to native iPhone applications.

    Is XMLV a viable way to develop iPhone applications using Java?

    Here are a few Java code examples used to build and application in an iPhone:

    http://www.xmlvm.org/iphone/#

  • Jacek
    Jacek over 14 years
    And here's even more on the technology: adobe.com/devnet/logged_in/abansod_iphone.html
  • Brendan Lesniak
    Brendan Lesniak over 14 years
    Well, I do know C#, some C++, and other languages, so maybe learning Objective-C won't be too hard for me. I'm just trying to get an idea of how difficult it would be if I were to use Java. My teacher just threw this at me today...
  • Brendan Lesniak
    Brendan Lesniak over 14 years
    Would help, but we only have a java compiler at my high school, though I do know C#...
  • Brendan Lesniak
    Brendan Lesniak over 14 years
    I know C++, C#, and some C...so yes I've done SOME C before...
  • Amir Afghani
    Amir Afghani over 14 years
    Why was this down-voted?
  • deanvmc
    deanvmc over 14 years
    Don't spread yourself too thing either, people have a habit of being aware of many languages but not very good at one. I would suggest to leave objective C off the list for a while and go play with the many Java SDK's that are floating about.
  • Chris Hanson
    Chris Hanson over 14 years
    The major difficulties for Java/C#/ActionScript/JavaScript folks are (1) the existence of and syntax for pointers and (2) manual memory management. Since you have some C++ and C under your belt, you should be able to pick up Objective-C relatively easily.
  • Pratik
    Pratik over 11 years
    Now it is possible with phone gap framework
  • Andiih
    Andiih over 11 years
    Worth noting that (now) Monotouch is xamarin.com/ios?gclid=CKu1juOp77UCFUbMtAodUnIAYg
  • setherj
    setherj almost 10 years
    Good list, these seem like they may be the top ones.
  • Christopher Fraser
    Christopher Fraser about 9 years
    RoboVM recently reached version 1.0
  • Brendan Lesniak
    Brendan Lesniak about 9 years
    This question was asked in end of 2009, beginning of 2010... but thanks for your input anyway.
  • simbo1905
    simbo1905 over 8 years
    Definitely anyone starting out from Java should be looking to write HTML5 frontends which work with desktop and mobile browsers and that can use Apache Cordova (phone gap) to be bumbled into native apps on every possible phone and tablet. Use jquery mobile as the skin and jquery for the Ajax then on the Java webserver try out a few technologies to see which ones are easy (eg Spring Boot is highly productive, modern, but good for s CV as a bridge into (possibly legacy) enterprise Java). For bonus marks use websockets not Ajax which will excite potential employers).
  • Maciek Łoziński
    Maciek Łoziński almost 8 years
    RoboVM is closed. robovm.com/robovm-winding-down
  • Quazi Irfan
    Quazi Irfan over 7 years
    Another relatively new option is Intel Multi-OS Engine. libgdx is using to deploy to iOS.
  • Lloyd Sargent
    Lloyd Sargent over 7 years
    Learn as many languages as you can. It will give you an appreciation of the power (and weaknesses) of each. I, personally, know about 10 languages—although I admit I’m rusty in some of them.
  • Crouching Kitten
    Crouching Kitten over 7 years
    The link to the tutorial is dead.
  • Brendan Lesniak
    Brendan Lesniak about 7 years
    Just a heads up this question is from 2010...
  • tmsppc
    tmsppc about 7 years
    -1 because this doesn't answer the question of "how to code with Java in iOS". I value the content of this answer, but it's not appropriate as an StackOverflow answer. This answer is discussing the benefits of taking a different approach, and the question seems to be clear about the need of not using a Mac nor Objective C.
  • Brendan Lesniak
    Brendan Lesniak almost 7 years
    This question was asked years ago by myself (almost 7 years ago...). Anyway, yeah Java must not be enough for a Software Engineer; but it sure pays my 6 figure salary. Yep. Not enough.
  • Rohitdev
    Rohitdev almost 7 years
    Because this page is turning up in the results and there will be people stumbling upon this page.
  • Admin
    Admin over 6 years
    Because you need to keep a focus and that's why this is not a good answer.
  • Jonathan
    Jonathan over 5 years
    Id say 1 year to master java, 3 years to master C++, and 3 months to master HTML5
  • cupiqi09
    cupiqi09 about 4 years
    @BrendanLesniak: So what? More recent answers to a topic that evolves as much as this one are always welcome, I'd say Even more so since it is still a Google top hit in 2020...
  • Noor Hossain
    Noor Hossain over 2 years
    So the question is "how"?