Logo Icon Logo
A Crowd-sourced Cookbook on Writing Great Android® Apps
GitHub logo Twitter logo OReilly Book Cover Art
Introduction: Inter-/Intra-Process CommunicationBack to Android Cookbook Home | Up to Chapter: Inter/Intra-Application Communication

Author: Ian Darwin ('idarwin')
In Published Edition? Yes
FormatLanguage: WikiFormat

Introduction: Inter-/Intra-Process Communication


Android offers a unique collection of mechanisms for inter- (and intra-) application communication. This chapter treats of the following:

Intents are commonly used to re-purpose existing components. For example, there is an Intent for sending email, which we have one recipe on in this chapter, and more details in later chapters. This will invoke the user's standard email application, or pop up a chooser if they haven't specified a default. This is usually the right choice, since the email will be coming from the user's device, it should appear to come from the user, so the user should see it and have a chance to read it before hitting Send.

There is another use case for email: sending private logs or debug messages to your own application server. While this can usually more readily be handled by a web service instead of email, there are cases where email makes sense for this purpose. In this case you typically do not want the user to be involved. A good solution here is to use the JavaMail API. We don't cover JavaMail in this book, but it is covered in a whole chapter of my previous Java Cookbook.

See Also