Package proguard.io
Class DataEntryWriterFactory
- java.lang.Object
-
- proguard.io.DataEntryWriterFactory
-
public class DataEntryWriterFactory extends java.lang.ObjectThis class can create DataEntryWriter instances based on class paths. The writers will wrap the output in the proper apks, jars, aars, wars, ears, and zips. \
-
-
Constructor Summary
Constructors Constructor Description DataEntryWriterFactory(ClassPool programClassPool, ResourceFilePool resourceFilePool, int modificationTime, StringMatcher uncompressedFilter, int uncompressedAlignment, boolean pageAlignNativeLibs, boolean mergeAarJars, java.security.KeyStore.PrivateKeyEntry[] privateKeyEntries)Creates a new DataEntryWriterFactory.DataEntryWriterFactory(ClassPool programClassPool, ResourceFilePool resourceFilePool, int modificationTime, StringMatcher uncompressedFilter, int uncompressedAlignment, boolean pageAlignNativeLibs, boolean mergeAarJars, java.security.KeyStore.PrivateKeyEntry[] privateKeyEntries, java.util.function.Function<DataEntryWriter,DataEntryWriter> alternativeClassDataEntryWriterProvider)Creates a new DataEntryWriterFactory.DataEntryWriterFactory(ClassPool programClassPool, ResourceFilePool resourceFilePool, StringMatcher uncompressedFilter, int uncompressedAlignment, boolean pageAlignNativeLibs, boolean mergeAarJars, java.security.KeyStore.PrivateKeyEntry[] privateKeyEntries, java.util.function.Function<DataEntryWriter,DataEntryWriter> alternativeClassDataEntryWriterProvider)Creates a new DataEntryWriterFactory.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DataEntryWritercreateDataEntryWriter(ClassPath classPath, int fromIndex, int toIndex, DataEntryWriter extraDataEntryWriter)Creates a DataEntryWriter that can write to the given class path entries.
-
-
-
Constructor Detail
-
DataEntryWriterFactory
public DataEntryWriterFactory(ClassPool programClassPool, ResourceFilePool resourceFilePool, int modificationTime, StringMatcher uncompressedFilter, int uncompressedAlignment, boolean pageAlignNativeLibs, boolean mergeAarJars, java.security.KeyStore.PrivateKeyEntry[] privateKeyEntries)
Creates a new DataEntryWriterFactory.- Parameters:
programClassPool- the program class pool to process.resourceFilePool- the resource file pool to process.modificationTime- the modification date and time of the zip entries, in DOS format.uncompressedFilter- an optional filter for files that should not be compressed.uncompressedAlignment- the desired alignment for the data of uncompressed entries.pageAlignNativeLibs- specifies whether to align native libraries at page boundaries.mergeAarJars- specifies whether to merge all jars in an Android library aar into a single jar.privateKeyEntries- optional private keys to sign jars.
-
DataEntryWriterFactory
public DataEntryWriterFactory(ClassPool programClassPool, ResourceFilePool resourceFilePool, int modificationTime, StringMatcher uncompressedFilter, int uncompressedAlignment, boolean pageAlignNativeLibs, boolean mergeAarJars, java.security.KeyStore.PrivateKeyEntry[] privateKeyEntries, java.util.function.Function<DataEntryWriter,DataEntryWriter> alternativeClassDataEntryWriterProvider)
Creates a new DataEntryWriterFactory.- Parameters:
programClassPool- the program class pool to process.resourceFilePool- the resource file pool to process.modificationTime- the modification date and time of the zip entries, in DOS format.uncompressedFilter- an optional filter for files that should not be compressed.uncompressedAlignment- the desired alignment for the data of uncompressed entries.pageAlignNativeLibs- specifies whether to align native libraries at page boundaries.mergeAarJars- specifies whether to merge all jars in an Android app bundle into a single jar.privateKeyEntries- optional private keys to sign jars.alternativeClassDataEntryWriterProvider- optional, to provide an alternative class writer, instead of the defaultClassDataEntryWriter.
-
DataEntryWriterFactory
public DataEntryWriterFactory(ClassPool programClassPool, ResourceFilePool resourceFilePool, StringMatcher uncompressedFilter, int uncompressedAlignment, boolean pageAlignNativeLibs, boolean mergeAarJars, java.security.KeyStore.PrivateKeyEntry[] privateKeyEntries, java.util.function.Function<DataEntryWriter,DataEntryWriter> alternativeClassDataEntryWriterProvider)
Creates a new DataEntryWriterFactory.- Parameters:
programClassPool- the program class pool to process.resourceFilePool- the resource file pool to process.uncompressedFilter- an optional filter for files that should not be compressed.uncompressedAlignment- the desired alignment for the data of uncompressed entries.pageAlignNativeLibs- specifies whether to align native libraries at page boundaries.mergeAarJars- specifies whether to merge all jars in an Android app bundle into a single jar.privateKeyEntries- optional private keys to sign jars.alternativeClassDataEntryWriterProvider- optional, to provide an alternative class writer, instead of the defaultClassDataEntryWriter.
-
-
Method Detail
-
createDataEntryWriter
public DataEntryWriter createDataEntryWriter(ClassPath classPath, int fromIndex, int toIndex, DataEntryWriter extraDataEntryWriter)
Creates a DataEntryWriter that can write to the given class path entries.- Parameters:
classPath- the output class path.fromIndex- the start index in the class path.toIndex- the end index in the class path.extraDataEntryWriter- a writer to which extra injected files can be written.- Returns:
- a DataEntryWriter for writing to the given class path entries.
-
-