public static class apkParser.AndroidManifestParser
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
java.util.Set<java.lang.String> |
actions |
java.util.Set<java.lang.String> |
categories |
private boolean |
debug |
private static int |
endDocTag
code taken from
http://stackoverflow.com/questions/2097813/how-to-parse-the-androidmanifest-xml-file-inside-an-apk-package
original author: http://stackoverflow.com/users/539612/ribo
The author has taken the code snippet from his own application published
as "PackageExlorer", see https://play.google.com/store/apps/details?id=org.andr.pkgexp
The code was adopted to produce a org.w3c.dom.Document data structure by [MC]
documentation about binary xml can be found at:
http://justanapplication.wordpress.com/category/android/android-binary-xml/
consider to replace this with one of
https://github.com/xiaxiaocao/apk-parser
http://code.google.com/p/axml/
https://github.com/joakime/android-apk-parser
|
private static int |
endTag |
java.lang.String |
minSdkVersion |
java.lang.String |
packageName |
java.util.Set<java.lang.String> |
permissions |
private static int |
startTag |
java.lang.String |
targetSdkVersion |
java.lang.String |
versionCode |
java.lang.String |
versionName |
Constructor and Description |
---|
apkParser.AndroidManifestParser(byte[] xml,
boolean debug) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
compXmlString(byte[] xml,
int sitOff,
int stOff,
int strInd) |
java.lang.String |
compXmlStringAt(byte[] arr,
int strOff)
Return the string stored in StringTable format at offset strOff.
|
private void |
decompressXML(byte[] xml)
Parse the 'compressed' binary form of Android XML docs such as for AndroidManifest.xml in .apk files
|
void |
evaluateTag(int indent,
java.lang.String tagName,
java.util.Map<java.lang.String,java.lang.String> attributes) |
int |
LEW(byte[] arr,
int off)
Return value of a Little Endian 32 bit word from the byte array at offset off.
|
private boolean debug
public java.lang.String versionCode
public java.lang.String versionName
public java.lang.String packageName
public java.lang.String minSdkVersion
public java.lang.String targetSdkVersion
public java.util.Set<java.lang.String> permissions
public java.util.Set<java.lang.String> actions
public java.util.Set<java.lang.String> categories
private static final int endDocTag
private static final int startTag
private static final int endTag
public apkParser.AndroidManifestParser(byte[] xml, boolean debug)
private void decompressXML(byte[] xml)
xml
- public java.lang.String compXmlString(byte[] xml, int sitOff, int stOff, int strInd)
public void evaluateTag(int indent, java.lang.String tagName, java.util.Map<java.lang.String,java.lang.String> attributes)
public java.lang.String compXmlStringAt(byte[] arr, int strOff)
arr
- strOff
- public int LEW(byte[] arr, int off)
arr
- off
-