| java.lang.Object | ||
| ↳ | java.lang.Enum<E extends java.lang.Enum<E>> | |
| ↳ | com.facebook.common.memory.MemoryTrimType | |
Types of memory trim.
Each type of trim will provide a suggested trim ratio.
A MemoryTrimmableRegistry implementation sends out memory trim events with this type.
| Enum Values | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| MemoryTrimType | OnAppBackgrounded | This app is moving into the background, usually because the user navigated to another app. | |||||||||
| MemoryTrimType | OnCloseToDalvikHeapLimit | The application is approaching the device-specific Java heap limit. | |||||||||
| MemoryTrimType | OnSystemLowMemoryWhileAppInBackground | The system as a whole is running out of memory, and this application is in the background. | |||||||||
| MemoryTrimType | OnSystemLowMemoryWhileAppInForeground | The system as a whole is running out of memory, and this application is in the foreground. | |||||||||
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| double |
getSuggestedTrimRatio()
Get the recommended percentage by which to trim the cache on receiving this event.
| ||||||||||
| static MemoryTrimType | valueOf(String name) | ||||||||||
| final static MemoryTrimType[] | values() | ||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Enum
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface
java.lang.Comparable
| |||||||||||
This app is moving into the background, usually because the user navigated to another app.
The application is approaching the device-specific Java heap limit.
The system as a whole is running out of memory, and this application is in the background.
The system as a whole is running out of memory, and this application is in the foreground.
Get the recommended percentage by which to trim the cache on receiving this event.