public class MissionPackageExtractor extends java.lang.Object implements IMissionPackageExtractor
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
VERSION_MATCHER |
static java.lang.String |
VERSION_MATCHER_ALT |
static java.lang.String |
XML_MATCHER |
Constructor and Description |
---|
MissionPackageExtractor() |
Modifier and Type | Method and Description |
---|---|
MissionPackageManifest |
extract(android.content.Context context,
java.io.File inFile,
java.io.File atakRoot,
boolean bImport)
Extract contents from the specified Zip File
|
static java.lang.String |
ExtractCoT(android.content.Context context,
java.io.File zipFilePath,
MissionPackageContent content,
boolean broadcast)
Extract CoT UID from zipFile, optionally broadcast CoT for internal processing by ATAK
|
static boolean |
ExtractFile(java.io.File zipFilePath,
MissionPackageContent content)
Extract fileName from zipFile into targetDirectory
|
MissionPackageManifest |
getManifest(java.io.File zipFile)
Extract manifest from the specified Zip File
|
static MissionPackageManifest |
GetManifest(java.io.File zip) |
static java.lang.String |
GetXmlAttribute(java.lang.String xml,
java.lang.String name)
Find "
|
static void |
UnzipFile(java.io.InputStream zis,
java.io.File file,
boolean renameIfExists,
byte[] buffer) |
public static final java.lang.String XML_MATCHER
public static final java.lang.String VERSION_MATCHER
public static final java.lang.String VERSION_MATCHER_ALT
public MissionPackageManifest extract(android.content.Context context, java.io.File inFile, java.io.File atakRoot, boolean bImport) throws java.io.IOException
IMissionPackageExtractor
extract
in interface IMissionPackageExtractor
context
- the context for the applicationinFile
- the zip file to unzipatakRoot
- where to unzip data and filesjava.io.IOException
public MissionPackageManifest getManifest(java.io.File zipFile)
IMissionPackageExtractor
getManifest
in interface IMissionPackageExtractor
public static MissionPackageManifest GetManifest(java.io.File zip)
public static void UnzipFile(java.io.InputStream zis, java.io.File file, boolean renameIfExists, byte[] buffer) throws java.io.IOException
java.io.IOException
public static boolean ExtractFile(java.io.File zipFilePath, MissionPackageContent content)
zipFilePath
- content
- public static java.lang.String ExtractCoT(android.content.Context context, java.io.File zipFilePath, MissionPackageContent content, boolean broadcast)
zipFilePath
- content
- public static java.lang.String GetXmlAttribute(java.lang.String xml, java.lang.String name)
xml
- name
-