O'Reilly logo

Android Studio Cookbook by Mike van Drongelen

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Content providers

Building a content provider is a really smart thing to do. The content provider API comes with an interesting feature that allows applications to observe changes in a data set.

Content providers connect data in one process with code running in another process, even between two completely different applications if you want. If you ever wrote code to pick an image from the Gallery app, you may have experienced this behavior. Some component manipulates the persistent dataset that other components depend upon. A content provider can use many different ways to store data, which can be stored in a database, in files, or even over a network.

Datasets are identified by unique URIs, so it is possible to ask for notifications if a certain ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required