2

I'm an experienced Android (with Eclipse) developer, and I'm looking to finally switch to Android Studio, but I want the same IDE for both Java and Android development.

I've been looking into using either IDEA IDE C.E. 14 with the Android plugin (default) vs the Android Studio.

Is it possible to load the "Java" project features into Android Studio? & How do you do it?

(I've looked and I don't see the same plugins in the list of plugins available for both, And even if I did find/get the same plugins... would it allow me to actually program (properly) Java code in Android Studio?)

EDIT: Answer Below, you do NOT need to import anything into Android Studio to have 'java' projects. Just have to circumvent there being no "new project wizard" for Java projects.

mawalker
  • 2,072
  • 2
  • 22
  • 34
  • 1
    "I've been looking into using either IDEA IDE C.E. 14 with the Android plugin (default) vs the Android Studio" Why would this not suffice ? – Deepak Bala Jan 03 '15 at 21:42
  • hmmm.. time to move android off eclipse and onto AS. definitely. if you were really dialed in (java/eclipse) for 'junit' for dependency injection for j2ee.... im not sure how happy ur gonna be trying to drag all that over from eclipse into AS or to intellij. – Robert Rowntree Jan 03 '15 at 22:05
  • @DeepakBala Because Android Studio is the "official" IDE, and I'm trying to figure this out for more than just myself. The material we'll be teaching has both Android and Java project components. So 'if possible' I'd like to have them install A.S. and then just add Java support to that. That way we are more consistent with "official" practices, etc. (Plus the Android plugin in A.S. is slightly ahead of the one in IDEA C.E.(Again, not a problem 'for me', but...)) – mawalker Jan 04 '15 at 00:47
  • Are you teaching these to students ? The enterprise version of IntelliJ is [free for students and teachers](https://www.jetbrains.com/student/). – Deepak Bala Jan 04 '15 at 12:04
  • Right now, just university students, but eventually MOOC students who don't count for the free version of intelleJ, but that doesn't matter, because its outside the scope of my original question. – mawalker Jan 04 '15 at 22:58

1 Answers1

0

Apparently you don't "need" to add "java support". It is already there (or at least mostly).

https://stackoverflow.com/a/26196451

As this answer states, you can (I've confirmed this myself) create a new project, and then add a "java library" ... then make it 'executable' (then delete the android part of the project even if you want.

I've even imported a maven project which had only java code. (no Android at all). (the import didn't do much other than wrap my maven project with gradle, but it at least "worked". (I'll have to go back and 'properly' convert the mvn project to gradle myself)

So you can easily make Android Studio work for "Java" programs without importing any additional IDEA modules, you just have to 'force' it to do it.

Community
  • 1
  • 1
mawalker
  • 2,072
  • 2
  • 22
  • 34