@Immutable
public class ManifestMerger2
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
ManifestMerger2.AutoAddingProperty
Defines a property that can add or override itself into an XML document.
|
static class |
ManifestMerger2.FileStreamProvider
A ManifestMerger2.FileStreamProvider provides (buffered, if necessary)
InputStream
instances for a given File handle. |
static class |
ManifestMerger2.Invoker<T extends ManifestMerger2.Invoker<T>>
This class will hold all invocation parameters for the manifest merging tool.
|
static class |
ManifestMerger2.MapBasedKeyBasedValueResolver<T>
Helper class for map based placeholders key value pairs.
|
static class |
ManifestMerger2.MergeFailureException |
static class |
ManifestMerger2.MergeType
Defines the merging type expected from the tool.
|
| Modifier and Type | Method and Description |
|---|---|
ManifestMerger2.FileStreamProvider |
getFileStreamProvider()
Returns the
ManifestMerger2.FileStreamProvider used by this manifest merger. |
static ManifestMerger2.Invoker |
newMerger(java.io.File mainManifestFile,
com.android.utils.ILogger logger,
ManifestMerger2.MergeType mergeType)
Creates a new
ManifestMerger2.Invoker instance to invoke
the merging tool to merge manifest files for an application. |
protected void |
performSystemPropertiesInjection(com.android.manifmerger.MergingReport.Builder mergingReport,
XmlDocument xmlDocument)
Perform
ManifestSystemProperty injection. |
@NonNull public ManifestMerger2.FileStreamProvider getFileStreamProvider()
ManifestMerger2.FileStreamProvider used by this manifest merger. Use this
to read files if you need to access the content of a XmlDocument.@NonNull public static ManifestMerger2.Invoker newMerger(@NonNull java.io.File mainManifestFile, @NonNull com.android.utils.ILogger logger, @NonNull ManifestMerger2.MergeType mergeType)
ManifestMerger2.Invoker instance to invoke
the merging tool to merge manifest files for an application.mainManifestFile - application main manifest file.logger - the logger interface to use.ManifestMerger2.Invoker instance that will allow
further customization and trigger the merging tool.protected void performSystemPropertiesInjection(@NonNull
com.android.manifmerger.MergingReport.Builder mergingReport,
@NonNull
XmlDocument xmlDocument)
ManifestSystemProperty injection.mergingReport - to log actions and errors.xmlDocument - the xml document to inject into.