To preserve on-device memory, how might you determine that the user’s device has limited storage capabilities?

✅  The correct answer is:

  • Use the ActivityManager.isLowRamDevice() method to find out whether a device defines itself as “low RAM.”

Question:

To preserve on-device memory, how might you determine that the user’s device has limited storage capabilities?

Solution:

  • Use the ActivityManager.isLowRamDevice() method to find out whether a device defines itself as “low RAM.”
  • Use the Activity.islowRam() method to find out whether a device defines itself as “low RAM.”
  • Use the ConnectivityManager.hasLowMemory() method to find out whether a device defines itself as “low RAM.”
  • Make an image download request and check the remaining device storage usage.