First look: Android Studio eclipses Eclipse

Google's new Android development environment pairs rich layout and build capabilities with IntelliJ IDEA's famous ease

Page 2 of 3

One of Android Studio's main contributions is a drag-and-drop set of tools for designing your Android layouts. You can drag around the widgets and the Studio will massage the XML underneath.

Another nice feature lets you pop up the design in six or so devices of various sizes. You can tweak the layout and see how it will be displayed in a Nexus phone or tablet. This is a wonderful innovation for Android developers who must design their apps to fit a large number of different screens. The Android stack does a pretty good job helping the widgets flow into the right places. The most important part of the debugging cycle is testing them. Being able to quickly view the design in multiple screen configurations is a godsend.

Adopting the tool requires a bit of relearning if you're coming to it from Eclipse. Not only are some of the buttons in different places, but Android Studio is heavily integrated with Gradle, the latest build tool. If you're still stuck on Ant or Maven, you'll have to adjust to yet another innovative solution to building your software where everything is slightly different. From the arrangement of the files to the languages, everything has morphed a bit.

A cloudy future

Not everything is ready yet. The Web pages promise, for instance, that Gradle will make it easier to create multiple build variants, but this won't happen until the future. I think the more flexible Gradle build system will be a welcome addition because apps are getting more complicated. When I tested the Studio, I built three different apps that started with a very similar code base. I used three different projects because that was simpler. This kind of work will be more common as we try to gather together more and more parts of a project under one umbrella.

It's worth noting that Gradle is the latest baroque instantiation of a trend toward domain-specific languages that are sometimes described as "mini-languages" with just enough custom structure to handle the job. In this case, Gradle is a Groovy DSL, which means you have to shift gears to think in Groovy and shift gears again to think in Gradle. But then deep in Android Studio you're really writing Java, which means you're writing and thinking in three slightly different but structurally similar languages. While I've always appreciated the idea behind DSLs, the complexity started to wear on me with Android Studio.

Alas, building an app has gotten so complex that we need a Turing-complete build language, so we might as well use the latest and greatest build tools -- today that may be Gradle. Only a tired, old Java hand would want to keep typing out all of those semicolons just to be consistent. The good news is that the cloud-based tools such as Hudson and Jenkins are embracing Gradle, so we can expect more and more projects to use it.

First look: Android Studio eclipses Eclipse
Android Studio lets you quickly view your layout on a number of Google's devices simultaneously.
| 1 2 3 Page 2
From CIO: 8 Free Online Courses to Grow Your Tech Skills
Notice to our Readers
We're now using social media to take your comments and feedback. Learn more about this here.