AaptParser

public class AaptParser
extends Object

java.lang.Object
   ↳ com.android.tradefed.util.AaptParser


Klasa, która wyodrębnia informacje z pliku APK przez analizę danych wyjściowych polecenia „aapt dump badging”.

aapt musi być na ścieżce PATH

Podsumowanie

Metody publiczne

String getLabel()
getNativeCode()
String getPackageName()
int getSdkVersion()
int getTargetSdkVersion()
String getVersionCode()
String getVersionName()
boolean isRequestingLegacyStorage()

Sprawdź, czy aplikacja prosi o przechowywanie danych w starszej wersji.

boolean isUsingPermissionManageExternalStorage()
static AaptParser parse(File apkFile, AaptParser.AaptVersion aaptVersion)

Przeanalizuj informacje z pliku APK.

static AaptParser parse(File apkFile)

Przeanalizuj informacje z pliku APK.

Metody publiczne

getLabel

public String getLabel ()

Zwroty
String

getNativeCode

public  getNativeCode ()

Zwroty

getPackageName

public String getPackageName ()

Zwroty
String

getSdkVersion

public int getSdkVersion ()

Zwroty
int

getTargetSdkVersion

public int getTargetSdkVersion ()

Zwroty
int

getVersionCode

public String getVersionCode ()

Zwroty
String

getVersionName

public String getVersionName ()

Zwroty
String

isRequestingLegacyStorage

public boolean isRequestingLegacyStorage ()

Sprawdź, czy aplikacja prosi o przechowywanie danych w starszej wersji.

Zwroty
boolean Zwraca wartość logiczną „true”, jeśli atrybut requestLegacyExternalStorage ma wartość „true” w pliku AndroidManifest.xml.

isUsingPermissionManageExternalStorage

public boolean isUsingPermissionManageExternalStorage ()

Zwroty
boolean

parsowanie

public static AaptParser parse (File apkFile, 
                AaptParser.AaptVersion aaptVersion)

Przeanalizuj informacje z pliku APK.

Parametry
apkFile File: plik apk

aaptVersion AaptParser.AaptVersion: wersja aapt

Zwroty
AaptParser AaptParser lub null, jeśli nie udało się wyodrębnić informacji

parsowanie

public static AaptParser parse (File apkFile)

Przeanalizuj informacje z pliku APK.

Parametry
apkFile File: plik apk

Zwroty
AaptParser AaptParser lub null, jeśli nie udało się wyodrębnić informacji