Monday, September 21, 2009

A Look at Android Development

I stumbled across this article on Android development today, and it was a very interesting read. The author gave a very balanced look at the Android platform, saying what he thought was good and bad. It reads like a very honest assessment. I didn't detect any obvious spin.

The one area where I don't agree with the author is his statement on Android's Intent/Activity model. This post claims that Android is "a big step ahead of the current iPhone programming model", but I can't help but to be reminded of OpenDoc and CyberDog. This idea of getting "away from monolithic, isolated applications" is not new; it's been floating around at least since the 1990s. If you look at theoretical, rather than practical implementations, it probably goes back much further than that, even.

Yet, here we are in 2009 still using monolithic applications.

Oh, wait, no we aren't. Not really.

When I write an iPhone application, much of the functionality I'm using wasn't written by me and isn't part of my application. It's part of a framework that's already on the phone. I think time has shown that the content-focused (or, intent-focused, if you will) way of dividing up code is problematic at best. It's great in theory, but problematic in practice.

In the example in the blog posting, how do I know if that barcode application is installed? What do I do if it's not? This approach opens up a huge number of problems with testing, installation, and development that offset any of the gains you get from not having code duplicated. The problems of Intent/activity are even more pronounced on an open platform like Android where the user has a lot of flexibility in terms of how they configure it and what they install on it.

This concept also just doesn't really fit the mobile application model that well. The iPhone isn't a general-purpose computer, and neither is an Android phone. If you look at the general population of consumers using smart phones, the way they use the phone the vast majority of the time really doesn't lend itself to this concept at all. They use and expect small applications to serve a defined, finite purpose.

If you're building megalithic applications for a smart phone, you're (quite simply) doing it wrong, and if you're not, you're not going to get all that much benefit from Intent/Activity, and you are going to pay a price in added complexity in the development process and the install process, not to mention greatly increasing the likelihood of problems for your customers.

That's not to say that the iPhone couldn't use some improvement in the inter-application communication arena. We currently have the ability to register application URLs, but it's a one-way trip. I can launch a barcode application, but I can't tell the barcode program to send me anything back unless I control both applications. In reality, I'm not sure how big of a limitation this really is, however. Most of the time, we're not going to want to rely on another application's functionality to handle an important application task unless the other app is one we wrote and have control over. If that's the case, then we have access to the source code and can included the functionality in the app and make it self-contained, greatly reducing the chance that our customers will have problems and get mad at us.



8 comments:

lkm said...

>They use and expect small applications to
> serve a defined, finite purpose.

Which is exactly why Intents are great, because they allow you to use other applications for stuff you dont' want to deal with. Some iPhone apps use URL handlers for this, but Intents are more powerful and better defined.

At any rate, Android couldn't work without something like Intents. Different cell phone manufacturers replace parts of Android (like the browser, or the messaging app). Intents make sure that all apps continue to work even if the parts of the OS they interact with are replaced.

Android wouldn't work without Intents, and at least so far, they work just fine.

I wish the iPhone would provide the same feature.

Jeff LaMarche said...

We'll have to agree to disagree on this, I guess. I don't feel like I'm missing this on the iPhone, nor do I see it as a particularly commendable part of Android's design myself.

I understand your argument about different cell phone manufacturers, but since you have to use a reverse domain name to specify not just the type of functionality, but the actual chunk of code and vendor, this seems like a very brittle and problematic approach.

It's called "intent", but that seems like a misnomer to me. The user doesn't "intend" to use a specific application or chunk of code, they "intend" to perform a task and for the most part, don't care what code allows them to do it.

I think the iPhone's URI-based mechanism is a better approach when you look at the way people use the device. If components get swapped out, you can change which application handles a URI-type and the calling application never has to know or care about whether it's org.android.Browser, or com.Opera that actually handles it. They just launch the URL, and the default application, or the user-specified application for that URL handles it.

Again, I see the value in theory, but it's a problematic approach in actual practice.

andy said...

In today’s internet savvy world an online presence is a must for any organization weather big or small, but just a mere website of the company wont serve the purpose of reaching out and impressing the target audience, your online presence should leave an impact on the mind of the viewers, and from here comes website designing and development companies of Delhi, search engine optimization and marketing companies of Delhi and internet marketing services providing companies of Delhi in picture. These companies provide end to end solutions for all your website related issues.

myworld85 said...

I can't tell the barcode program to send me anything back unless I control both applications. In reality, I'm not sure how big of a limitation this really is, however. Most of the time,Interworld Commnet provides iphone and mobile application development, web & intranet application development, seo and internet marketing.http://www.innovativepeople.com/iphone.html

ProgMasta said...

I think you all are looking at it from the wrong prospective. See what matters is who is using the app. Obviously that would be the owner of the phone. The difference of how the two work is to be judged by the user. Which is why I believe android will be more successful in the long run. The intent procedure allows for more "choice" by the end-user. If I(as a programmer) write a program I "intend" for it to something specific and the user "intends" to have that specific task done. Now another programmer can write a program that does the same task only maybe it has it different interface. Now as much as I'd like to say that my program completes the task in a more efficient way, and even if it actually does, it does doesn't really matter. What really matters is that the end-user is satisfied. So just maybe this end-user does not think my program is very intuitive and so the program the other developer wrote is in their opinion easier to use. Even if it is less efficient if the end-user prefers the interface then it's likely this will be there choice. Well purpose of the intents is that each user gets the opportunity to make that decision for themselves.

Think about it... Compare the difference between macs and pc's. Even though macs are far less likely to give a person a headache. The ability to easily update/upgrade any part of pc has caused microsoft to grow. I fix computers for a living and less than 1% of the calls I get are about macs. Yes macs are becoming more and more populare, but I hardly believe the will ever become the majority.

By the way for the comment someone made about how you don't have control of the app with intents. Well duuuuhhh! Thats not what the intents are designed to do. What it's designed for is so that if someone has written a program that completes a task that you also intend your program to complete. Then you don't have to reinvent the wheel. In other words you can Add to the functionality but not take away from it. Therefore you can only use the program for exactly what it was intended for. Obviously if have a need to manipulate the output of the program then your program doesn't exactly intend to do the same thing. So think of the entire program as a "function" of your program. You can call the function and it does exactly what the programmer intended it to do and then you use the result to do something else. But if you need the function to do something else then you override the function. Right? So in overriding the function you change it's intent. Which is exactly the purpose of the intents. So in the case where the function is an entire program written by someone else, then in order to override it you have to write the program yourself. And is the intent of intents. Haha.

Edwin said...

scrub m65 kamagra attorney lawyer body scrub field jacket lovegra marijuana attorney injury lawyer

Silvio said...

Thanks for sharing, I will bookmark and be back again
Mobile Applications Development

h4ns said...

What youre saying is completely true. I know that everybody must say the same thing, but I just think that you put it in a way that everyone can understand. I also love the images you put in here. They fit so well with what youre trying to say. Im sure youll reach so many people with what youve got to say.

Arsenal vs Huddersfield Town live streaming
Arsenal vs Huddersfield Town live streaming
Wolverhampton Wanderers vs Stoke City Live Streaming
Wolverhampton Wanderers vs Stoke City Live Streaming
Notts County vs Manchester City Live Streaming
Notts County vs Manchester City Live Streaming
Bologna vs AS Roma Live Streaming
Bologna vs AS Roma Live Streaming
Juventus vs Udinese Live Streaming
Juventus vs Udinese Live Streaming
Napoli vs Sampdoria Live Streaming
Napoli vs Sampdoria Live Streaming
Fulham vs Tottenham Hotspur Live Streaming
Fulham vs Tottenham Hotspur Live Streaming
AS Monaco vs Marseille Live Streaming
AS Monaco vs Marseille Live Streaming
Alajuelense vs Perez Zeledon Live Streaming
Alajuelense vs Perez Zeledon Live Streaming
Technology News | News Today | Live Streaming TV Channels