Class LibStorageUtils
- 
                    
                    - All Implemented Interfaces:
 
 public class LibStorageUtilsCreated by Android Studio. User: lvhongzhen Date: 2019-12-02 Time: 14:49 
- 
                
                    
                    - 
                                
                            
                                Field SummaryFields Modifier and Type Field Description public final static StringDIRpublic final static StringVIDEOpublic final static StringIMAGEpublic final static StringFILEpublic final static StringAUDIOpublic final static StringMEDIApublic final static StringDB_STORAGEpublic final static StringDB_STORAGE_PRIVATE
 - 
                                
                            
                                Constructor SummaryConstructors Constructor Description LibStorageUtils()
 - 
                                
                            
                                Method SummaryModifier and Type Method Description static booleanisScopedStorageMode(Context context)Indicates whether the app is in partitioned storage mode. static booleanisBuildAndTargetForQ(Context context)Indicates whether the Android SDK version is >= Build.VERSION_CODES.Qand the target SDK version is>= Build.VERSION_CODES.Q.static booleanisOsAndTargetForR(Context context)static StringgetMediaDownloadDir(Context context)Retrieves the storage path for media files. static StringgetMediaDownloadDir(Context context, String dir)Retrieves the storage path for media files static StringgetFilesDir(Context pContext, String dir)static StringgetAppName(Context context)Retrieves the application name - 
                    
                    
                    - 
                                
                            
                                Method Detail- 
                                        isScopedStorageModestatic boolean isScopedStorageMode(Context context) Indicates whether the app is in partitioned storage mode. For apps targeting Android 11 targetSdkVersion>=30, you must setrc_q_storage_mode_enabletotrue; otherwise, sending media files such as images and documents will fail.- Parameters:
- context- The context
- Returns:
- Whether the app is in Android 11 storage mode 
 
 - 
                                        isBuildAndTargetForQstatic boolean isBuildAndTargetForQ(Context context) Indicates whether the Android SDK version is >= Build.VERSION_CODES.Qand the target SDK version is>= Build.VERSION_CODES.Q.- Parameters:
- context- The context
- Returns:
- Whether the Android SDK version is - >= Build.VERSION_CODES.Qand the target SDK version is- >= Build.VERSION_CODES.Q
 
 - 
                                        isOsAndTargetForRstatic boolean isOsAndTargetForR(Context context) - Returns:
- Indicates whether the system version is - >=Rand the target platform is- target >= Build.VERSION_CODES.R
 
 - 
                                        getMediaDownloadDir@Deprecated() static String getMediaDownloadDir(Context context) Retrieves the storage path for media files. - Parameters:
- context- The context.
- Returns:
- The storage path for media files. 
 
 - 
                                        getMediaDownloadDirstatic String getMediaDownloadDir(Context context, String dir) Retrieves the storage path for media files - Parameters:
- context- The context
- dir- The custom directory
- Returns:
- The storage path for media files 
 
 - 
                                        getFilesDirstatic String getFilesDir(Context pContext, String dir) 
 - 
                                        getAppNamestatic String getAppName(Context context) Retrieves the application name - Parameters:
- context- The context
- Returns:
- The application name 
 
 
- 
                                        
 
- 
                                
                            
                                
 
- 
                    
                    
                    
 
-