Develop iOS apps using Java

Asked

Viewed 10,133 times

1

I am developing my TCC and it is based on the multiplatform concept of Java. But now I ran into a problem Xcode IDE Apple does not understand the Java packages.

Is there a tool or extension that allows me to develop my iOS application in Java?

  • 1

    as far as I know in Xcode Objective C is used only

  • The opposite of that (Objective-C for Java/Android) can be done through this tool apportable, that for now works well with games.

  • Develop your app by coding it in Java for android in Eclipse and... ...use the http://gluonhq.com/the-new-gluon-plugin-for-eclipse/ eclipse plugin to generate your iOS S.O. app used on iPhones from the same Java code!

4 answers

3

If you want to develop to OSX, which is the Mac system, you can use Ides like Eclipse, Netbeans or Intellij Idea.

Already the iOS is the iPhone/iPad system and its applications are developed natively in the Objective-C language, which is an extension of C.

I don’t think iOS supports programming in Java (there may even be a framework for this, since for Android it is possible to "program" in Delphi or C# using third-party frameworks (with Delphi XE6 and Xamarin, respectively). I say "program" in quotes because not all features can be supported - to exploit all the capabilities of a platform, you have to program using the language and libraries that offer these features natively).

But even if there is a way to program using Java, it will not be an example of the concept of cross-platform Java as you want, because Delphi for example is not cross-platform and does not run on mobile devices, but it is still possible to "program" for Android (and for iOS) using Delphi (the generated application is not compiled in Delphi but in the native language of the mobile platform; Delphi was only used to generate an intermediate representation of the code).

If you want to represent the concept of multiplatform for mobile devices, this will be better represented by the use of HTML/CSS/Javascript and some library of the type Phonegap, Titanium, etc., that will make your code run practically without modifications (but with some limitations) on various mobile systems such as Android, iOS, Windows Phone, Blackberry, Firefox OS, etc.

The cross-platform behavior of Java is not well represented on mobile devices except for Android, this behavior has been aimed more to allow the "write Once, run Anywhere" on desktop systems and servers.

2

In the eyes of Apple, you can only use the Xcode in his Mac, developing with Objective-C or Swift. I say this because otherwise than this, in a way goes against company principles.

You can find other ways, using HTML 5, Javascript and CSS with Phonegap and generate a hybrid application for iOS, or using C# with the Xamarin and even for your case, the Robovm with Java.

But like I said, these are options that nay are recognized by Apple, and depending on their purpose or for publication purposes on App Store, your application can be rejected. But each case is a case, I can’t say with 100% certainty.

  • 4

    Company with complicated principles, right?

0

It is not possible to develop applications for iOS using Java, the official programming language to develop for iOS is Objective-C. Created by Apple.

If you want to use Java I advise developing to Android.

0

In this Link there is reference to a plugin called Codename One free of charge and open-source for eclipse or Netbeans that lets you develop in java for iOS

In the website of them there are several cases of applications for various platforms beyond iOS, but not forgetting what was said by @Piovezan is a fact. Not all standard language features may be available and the result may not be as performative as native code.

  • A comment made in the cited link also speaks of Playn, which sounds interesting. But unfortunately none of these solutions represents "the multiplatform concept of Java", as OP wants.

  • @Piovezan apparently the Codenameone promises to take advantage of the code on all platforms q it supports, but as will be several types of devices, it will be necessary adjustments, q is already necessary to make an app for a desktop, web and android.

  • 1

    Yes. But even if no adjustments were needed, what I meant was that the various commercially available mobile devices do not run applications in a JVM (except for the old J2ME apps and DVM, which is the modified Android JVM) and therefore do not reproduce the cross-platform behavior of Java as in the case of the main desktop platforms. I commented this with the OP’s TCC proposal in mind.

  • Really @Piovezan. I agree with you, had not thought on this side. Thank you for the point of view.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.