AppVersionFetcher
public final class AppVersionFetcher
extends Object
java.lang.Object | |
↳ | com.android.tradefed.util.AppVersionFetcher |
デバイスからアプリのバージョン文字列を取得するユーティリティ クラス。
dumpsys パッケージ コマンドをデバイスに送信し、返された結果の文字列を解析します。
まとめ
パブリック コンストラクター | |
---|---|
AppVersionFetcher () |
公開メソッド | |
---|---|
static String | fetch ( ITestDevice device, String packageName, AppVersionFetcher.AppVersionInfo info) パッケージ名に基づいてアプリケーションのバージョン文字列を取得します。 |
パブリック コンストラクター
AppVersionFetcher
public AppVersionFetcher ()
公開メソッド
フェッチ
public static String fetch (ITestDevice device, String packageName, AppVersionFetcher.AppVersionInfo info)
パッケージ名に基づいてアプリケーションのバージョン文字列を取得します。
パラメーター | |
---|---|
device | ITestDevice : ITestDevice、デバイス インスタンス |
packageName | String : 文字列、パッケージ名 |
info | AppVersionFetcher.AppVersionInfo : AppVersionInfo、アプリのバージョン情報タイプ |
戻り値 | |
---|---|
String | パッケージのバージョン文字列 |
スロー | |
---|---|
DeviceNotAvailableException |