Package com.facebook.soloader
Class NativeDepsUnpacker
- java.lang.Object
-
- com.facebook.soloader.NativeDepsUnpacker
-
public final class NativeDepsUnpacker extends java.lang.ObjectUnpacks native deps file from APK to disk. Only needed when native deps are compressed in the APK. The file is extracted on first start, and replaced if the file is corrupt or the APK changes.
-
-
Method Summary
Modifier and Type Method Description static voidensureNativeDepsAvailable(android.content.Context context)Makes sure that the native deps file has been extracted from the APK to disk so it can be used to load libraries.static java.io.FilegetNativeDepsDir(android.content.Context context)static java.io.FilegetNativeDepsFilePath(android.content.Context context)
-
-
-
Method Detail
-
getNativeDepsFilePath
public static java.io.File getNativeDepsFilePath(android.content.Context context)
-
getNativeDepsDir
public static java.io.File getNativeDepsDir(android.content.Context context)
-
ensureNativeDepsAvailable
public static void ensureNativeDepsAvailable(android.content.Context context) throws java.io.IOExceptionMakes sure that the native deps file has been extracted from the APK to disk so it can be used to load libraries. If either the file hasn't been extracted, the extracted file is corrupt, or the APK changed, the file will be extracted from the APK. If the file was already extracted, this is a no-op. If extraction fails, an IOException will be thrown.- Parameters:
context- application context- Throws:
java.io.IOException- IOException
-
-