In the previous video I showed one way of caching bitmaps in memory. But you might instead want to cache them in persistent storage, so they don’t have to be downloaded every time the app loads or changes configuration.
- [Narrator] In the previous video,…I described one way of caching bitmaps in memory,…but you might instead want to cache these files…in persistent storage, so they don't have to be downloaded…every time the app loads or changes configuration.…I've created a simple utility class already…that will do some of this work for me.…I'm working in a version of my application now,…and I'll create a new Java class…in the utils package, that I'll name image cache manager.…Then, I'll go get the code for this new class…from a Gist that I've already created.…
The short URL for the Gist is git dot I-O…slash lowercase-V one uppercase-F-S-Y.…Here's the code,…and I'll select and copy it to the clipboard.…Then over in Android Studio…I'll delete the class declaration,…and paste that code into place.…Let's take a look at what it's doing.…First I have a method named get bitmap.…It receives a context reference and a data item object.…It calculates a URL where that image might be stored.…
It's looking for the image in the cache directory.…
IInstructor David Gassner starts with an overview discussion about available networking strategies, and then dives into how to declare networking permissions, make network requests, handle responses, parse data returned from a web service, and pass user credentials to services that support HTTP basic authentication. He also provides an overview of popular higher-level networking libraries, including OkHttp and Picasso, and offers recommendations for improving performance in network-connected apps. David also covers using static feeds, using dynamic PHP pages hosted on a public server web service, and integrating apps with network data storage.
- Integrating mobile apps
- Communicating with Android
- Preventing app freezes with background threads
- Preparing an app for network communication
- Declaring permissions
- Checking network connectivity
- Retrieving data over the web
- Using traditional APIs
- Using third-party libraries
Skill Level Intermediate
Android App Development: Communicating with the Userwith Joe Marini1h 12m Intermediate
Android App Development: Data Persistence Librarieswith Annyce Davis4h 52m Intermediate
Android App Development: Unit Testingwith James P White2h 58m Intermediate
Google Firebase for Android: First Lookwith Joe Marini1h 16m Intermediate
1. Getting Started
2. Manage Multithreading in Android
3. Requesting Data over the Web
4. Working with Binary Responses
5. Sending Data to Web Services
6. Manage HTTP Requests with Libraries
7. Manage RESTful APIs with Retrofit 2
Next steps1m 14s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.