Android - First impressions

 
10/28/2010
Android
0 Comments

The Android market share is continuously growing. So I decided to create a Yahtzee application to get some experience in android development. In this post I will compare Windows Phone 7, which has recently been launched, to the Android platform from a developer perspective.

First impressions

Android

To get started with Android you need the SDK and a plugin for Eclipse.
The developer guide, reference and the tutorials provided by Google are really good and provide all information you need to create an application.

Android applications are created in Java, with all its strengths and weaknesses. One problem is, that the view and the controller are not really separated. Views are defined in XML files, but since databinding is not supported in Android, you have to access view components from an Activity in the following way:

Button button = (Button)findViewById(R.id.my_button);

That approach is quite bad, since the Activity needs detailed knowledge of the UI and a cast is required to access the component. That means you have to write a lot of UI related code, which clatters your "other" code and makes it hard to write clean code with clear separation of concerns.

Pro AndroidContra Android
  • Growing market share
  • Good documentation
  • Open platform
  • Old fashioned programming model:
    • No clear separation between controller/activity and view
    • No support for delegates and events
    • Poor theming support
  • No designer tools
  • Many different devices with different capabilities

Windows Phone 7

Microsoft provides the necessary development tools for free. If you already worked with Silverlight using Visual Studio and Expression Blend, development for Windows Phone will be quite familiar to you.

The provided tools enable you to build applications quickly. Since Silverlight supports databinding you can create "clean" code applications based on the MVVM pattern. You could use frameworks like Caliburn as well.

Pro WP7Contra WP7
  • Great (designer) tools
  • Modern platform and programming model
  • Very well known devices
  • Currently only few users
  • Missing features (Copy/Past, SD card access, multitasking, ...)
  • Closed platform

Conclusion

In my opinion Microsoft provides a better developing experience. Java has never been first choice for graphical applications, and Java 6 is quite outdated and lacks many features compared to C#. Google included the ability to create views in XML, but that approach is much less powerful than XAML.
Most (business) applications have to be available for all platforms. So maybe Monodroid is a good choice to reuse some code.

Feedly Feedly Tweet


Related posts


Comments