类 AndroidLocation
java.lang.Object
io.github.amsonix.molt.internal.reschiper.android.AndroidLocation
Manages the location of Android files, including emulator files, ddms config, and the debug keystore.
-
嵌套类概要
嵌套类修饰符和类型类说明static final classException thrown when the location of the Android folder couldn't be found. -
字段概要
字段修饰符和类型字段说明static final StringVirtual Device folder inside the path returned bygetFolder().static final StringThe name of the `.android` folder returned bygetFolder(). -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static voidCheck if ANDROID_SDK_HOME variable points to an SDK.static StringReturns the folder where the users AVDs are stored.static StringReturns the folder used to store Android-related files.static @Nullable StringReturns the folder used to store Android-related files.static @NotNull StringReturns the user's home folder.static voidResets the folder used to store Android-related files.
-
字段详细资料
-
FOLDER_DOT_ANDROID
The name of the `.android` folder returned bygetFolder().- 另请参阅:
-
FOLDER_AVD
Virtual Device folder inside the path returned bygetFolder().- 另请参阅:
-
-
构造器详细资料
-
AndroidLocation
public AndroidLocation()
-
-
方法详细资料
-
getFolder
Returns the folder used to store Android-related files. If the folder does not exist yet, it will be created.- 返回:
- An OS-specific path, terminated by a separator.
- 抛出:
AndroidLocation.AndroidLocationException- If an error occurs while creating the folder.
-
getFolderWithoutWrites
Returns the folder used to store Android-related files. This method will not create the folder if it doesn't exist yet.- 返回:
- An OS-specific path, terminated by a separator, or null if no path is found or an error occurs.
-
checkAndroidSdkHome
Check if ANDROID_SDK_HOME variable points to an SDK.- 抛出:
AndroidLocation.AndroidLocationException- If ANDROID_SDK_HOME is not correctly set.
-
getAvdFolder
Returns the folder where the users AVDs are stored.- 返回:
- An OS-specific path, terminated by a separator.
- 抛出:
AndroidLocation.AndroidLocationException- If an error occurs while obtaining the AVD folder path.
-
getUserHomeFolder
@NotNull public static @NotNull String getUserHomeFolder() throws AndroidLocation.AndroidLocationExceptionReturns the user's home folder.- 返回:
- An OS-specific path, terminated by a separator.
- 抛出:
AndroidLocation.AndroidLocationException- If an error occurs while obtaining the user's home folder path.
-
resetFolder
public static void resetFolder()Resets the folder used to store Android-related files. For testing.
-