Home
last modified time | relevance | path

Searched refs:ZFile (Results 1 – 25 of 25) sorted by relevance

/tools/apkzlib/src/test/java/com/android/tools/build/apkzlib/zip/
DZFileTest.java71 try (ZFile zf = new ZFile(zpath)) { in getZipPath()
80 try (ZFile azf = new ZFile(zf)) { in readNonExistingFile()
92 try (ZFile azf = new ZFile(zf)) { in readExistingEmptyFile()
103 try (ZFile azf = new ZFile(zf)) { in readAlmostEmptyZip()
116 try (ZFile azf = new ZFile(zf)) { in readZipWithTwoFilesOneDirectory()
149 try (ZFile zf = new ZFile(testZip)) { in readOnlyZipSupport()
162 try (ZFile zf = new ZFile(testZip)) { in readOnlyV2SignedApkSupport()
181 try (ZFile zf = new ZFile(testZip)) { in compressedFilesReadableByJavaZip()
230 try (ZFile zf = new ZFile(zipFile)) {
266 ZFile zf = new ZFile(zipFile);
[all …]
DZFileReadOnlyTest.java38 new ZFile(new File(temporaryFolder.getRoot(), "foo.zip"), new ZFileOptions(), true); in cannotCreateRoFileOnNonExistingFile()
48 try (ZFile zf = new ZFile(zip)) { in makeTestZip()
57 try (ZFile zf = new ZFile(makeTestZip(), new ZFileOptions(), true)) { in cannotUpdateInRoMode()
69 try (ZFile zf = new ZFile(makeTestZip(), new ZFileOptions(), true)) { in cannotAddFilesInRoMode()
82 try (ZFile zf = new ZFile(makeTestZip(), new ZFileOptions(), true)) { in cannotAddRecursivelyInRoMode()
94 try (ZFile zf = new ZFile(makeTestZip(), new ZFileOptions(), true)) { in cannotReplaceFilesInRoMode()
106 try (ZFile zf = new ZFile(makeTestZip(), new ZFileOptions(), true)) { in cannotDeleteFilesInRoMode()
120 try (ZFile toMerge = new ZFile(new File(temporaryFolder.getRoot(), "a.zip"))) { in cannotMergeInRoMode()
121 try (ZFile zf = new ZFile(makeTestZip(), new ZFileOptions(), true)) { in cannotMergeInRoMode()
134 try (ZFile zf = new ZFile(makeTestZip(), new ZFileOptions(), true)) { in cannotTouchInRoMode()
[all …]
DAlignmentTest.java58 try (ZFile zf = new ZFile(newZFile, options)) { in addAlignedFile()
74 try (ZFile zf = new ZFile(newZFile, options)) { in addNonAlignedFile()
89 try (ZFile zf = new ZFile(newZFile)) {
106 try (ZFile zf = new ZFile(newZFile, options)) {
133 try (ZFile zf = new ZFile(newZFile)) {
142 try (ZFile zf = new ZFile(newZFile, options)) {
176 try (ZFile zf = new ZFile(newZFile, options)) {
184 try (ZFile zf = new ZFile(newZFile)) {
201 try (ZFile zf = new ZFile(newZFile)) {
207 try (ZFile zf = new ZFile(newZFile, options)) {
[all …]
DExtraFieldTest.java97 try (ZFile zf = new ZFile(mZipFile)) { in readEntryWithNoExtraField()
125 try (ZFile zf = new ZFile(mZipFile)) { in readSingleExtraField()
172 try (ZFile zf = new ZFile(mZipFile)) { in readMultipleExtraFields()
199 try (ZFile zf = new ZFile(mZipFile)) { in addExtraFieldToExistingEntry()
205 try (ZFile zf = new ZFile(mZipFile)) { in addExtraFieldToExistingEntry()
216 try (ZFile zf = new ZFile(mZipFile)) { in addExtraFieldToExistingEntry()
241 try (ZFile zf = new ZFile(mZipFile)) { in removeExtraFieldFromExistingEntry()
247 try (ZFile zf = new ZFile(mZipFile)) { in removeExtraFieldFromExistingEntry()
258 try (ZFile zf = new ZFile(mZipFile)) { in removeExtraFieldFromExistingEntry()
264 try (ZFile zf = new ZFile(mZipFile)) { in removeExtraFieldFromExistingEntry()
[all …]
DZFileNotificationTest.java115 try (ZFile zf = new ZFile(new File(mTemporaryFolder.getRoot(), "a.zip"))) { in notifyAddFile()
138 try (ZFile zf = new ZFile(new File(mTemporaryFolder.getRoot(), "a.zip"))) { in notifyRemoveFile()
161 try (ZFile zf = new ZFile(new File(mTemporaryFolder.getRoot(), "a.zip"))) { in notifyUpdateFile()
188 try (ZFile zf = new ZFile(new File(mTemporaryFolder.getRoot(), "a.zip"))) { in notifyOpenUpdateClose()
212 try (ZFile zf = new ZFile(new File(mTemporaryFolder.getRoot(), "a.zip"))) { in notifyOpenUpdate()
234 try (ZFile zf = new ZFile(new File(mTemporaryFolder.getRoot(), "a.zip"))) { in notifyUpdate()
259 try (ZFile zf = new ZFile(new File(mTemporaryFolder.getRoot(), "a.zip"))) { in removedListenersAreNotNotified()
281 try (ZFile zf = new ZFile(new File(mTemporaryFolder.getRoot(), "a.zip"))) { in actionsExecutedAtEndOfNotification()
346 try (ZFile zf = new ZFile(zipFile)) { in canAddFilesDuringUpdateNotification()
375 try (ZFile zf2 = new ZFile(zipFile)) { in canAddFilesDuringUpdateNotification()
[all …]
DZipMergeTest.java50 try (ZFile mergedZf = new ZFile(merged)) { in mergeZip()
51 mergedZf.mergeFrom(new ZFile(aZip), f -> false); in mergeZip()
86 mergedZf.mergeFrom(new ZFile(bZip), f -> false); in mergeZip()
104 ZFile fooZf = closer.register(new ZFile(foo)); in mergeZipWithDeferredCrc()
111 ZFile merged = closer.register(new ZFile(new File(mTemporaryFolder.getRoot(), "bar"))); in mergeZipWithDeferredCrc()
142 ZFile fooZf = closer.register(new ZFile(foo)); in mergeZipKeepsDeflatedAndStored()
152 ZFile merged = closer.register(new ZFile(new File(mTemporaryFolder.getRoot(), "bar"))); in mergeZipKeepsDeflatedAndStored()
190 ZFile fooZf = new ZFile(foo); in mergeZipWithSorting()
191 ZFile merged = new ZFile(new File(mTemporaryFolder.getRoot(), "bar"))) { in mergeZipWithSorting()
DReadWithDifferentCompressionLevelsTest.java33 try (ZFile read = new ZFile(l9File, new ZFileOptions())) { in readL9()
43 try (ZFile read = new ZFile(l1File, new ZFileOptions())) { in readL1()
DZipToolsTest.java107 … private static void assertFileInZip(@Nonnull ZFile zfile, @Nonnull String name) throws Exception { in assertFileInZip()
121 try (ZFile zf = new ZFile(cloneZipFile())) { in zfileReadsZipFile()
155 try (ZFile zf = new ZFile(zfile, options)) { in testReadZFile()
DZFileSortTest.java37 private ZFile mZFile;
78 mZFile = new ZFile(mFile, options); in setupZFile()
192 mZFile = new ZFile(mFile, options); in sortFilesWithAlignment()
207 mZFile = new ZFile(mFile); in sortFilesOnClosedFile()
DOldApkReadTest.java33 try (ZFile zf = new ZFile(apkFile, new ZFileOptions())) { in testReadOldApk()
/tools/apkzlib/src/test/java/com/android/tools/build/apkzlib/sign/
DJarSigningTest.java26 import com.android.tools.build.apkzlib.zip.ZFile;
50 try (ZFile zf = new ZFile(zipFile)) { in signEmptyJar()
62 try (ZFile verifyZFile = new ZFile(zipFile)) { in signEmptyJar()
79 try (ZFile zf1 = new ZFile(zipFile)) { in signJarWithPrexistingSimpleTextFilePre18()
85 try (ZFile zf2 = new ZFile(zipFile)) { in signJarWithPrexistingSimpleTextFilePre18()
91 try (ZFile zf3 = new ZFile(zipFile)) { in signJarWithPrexistingSimpleTextFilePre18()
134 try (ZFile zf1 = new ZFile(zipFile)) { in signJarWithPrexistingSimpleTextFilePos18()
142 try (ZFile zf2 = new ZFile(zipFile)) { in signJarWithPrexistingSimpleTextFilePos18()
148 try (ZFile zf3 = new ZFile(zipFile)) { in signJarWithPrexistingSimpleTextFilePos18()
193 try (ZFile zf = new ZFile(zipFile)) { in v2SignAddsApkSigningBlock()
[all …]
DManifestGenerationTest.java25 import com.android.tools.build.apkzlib.zip.ZFile;
48 try (ZFile zf = new ZFile(zip)) { in elementaryManifestGeneration()
83 ZFile zf = closer.register(new ZFile(zip)); in manifestGenerationOnHalfWrittenFile()
119 ZFile zf = closer.register(new ZFile(zip)); in manifestGenerationOnExistingFile()
157 ZFile zf = closer.register(new ZFile(zip)); in manifestGenerationOnIncrementalNoChanges()
173 zf = closer.register(new ZFile(zip)); in manifestGenerationOnIncrementalNoChanges()
DFullApkSignTest.java27 import com.android.tools.build.apkzlib.zip.ZFile;
65 ZFile zf = new ZFile(out, options); in testSignature()
92 ZFile zf2 = new ZFile(out); in testSignature()
/tools/apkzlib/src/test/java/com/android/tools/build/apkzlib/zfile/
DApkAlignmentTest.java26 import com.android.tools.build.apkzlib.zip.ZFile;
64 try (ZFile zf = new ZFile(apk)) { in soFilesUncompressedAndAligned()
81 try (ZFile zf = new ZFile(zipToMerge)) { in soFilesMergedFromZipsCanBeUncompressedAndAligned()
85 try (ZFile zf = new ZFile(zipToMerge)) { in soFilesMergedFromZipsCanBeUncompressedAndAligned()
117 try (ZFile zf = new ZFile(apk)) { in soFilesMergedFromZipsCanBeUncompressedAndAligned()
161 try (ZFile zf = new ZFile(apk)) { in soFilesUncompressedAndNotAligned()
178 try (ZFile zf = new ZFile(zipToMerge)) { in soFilesMergedFromZipsCanBeUncompressedAndNotAligned()
182 try (ZFile zf = new ZFile(zipToMerge)) { in soFilesMergedFromZipsCanBeUncompressedAndNotAligned()
214 try (ZFile zf = new ZFile(apk)) { in soFilesMergedFromZipsCanBeUncompressedAndNotAligned()
/tools/apkzlib/src/test/java/com/android/tools/build/apkzlib/zip/compress/
DMultiCompressorTest.java27 import com.android.tools.build.apkzlib.zip.ZFile;
64 try (ZFile zf = new ZFile(zip)) { in storeIsBest()
83 try (ZFile zf = new ZFile(zip)) { in sameCompressionResultButBetterThanStore()
114 ZFile defaultZFile = new ZFile(defaultFile);
115 ZFile resultZFile = new ZFile(resultFile, resultOptions)) {
144 ZFile defaultZFile = new ZFile(defaultFile);
145 ZFile resultZFile = new ZFile(resultFile, resultOptions)) {
/tools/apkzlib/src/main/java/com/android/tools/build/apkzlib/zfile/
DZFiles.java23 import com.android.tools.build.apkzlib.zip.ZFile;
65 public static ZFile apk(@Nonnull File f, @Nonnull ZFileOptions options) throws IOException { in apk()
68 return new ZFile(f, options); in apk()
92 public static ZFile apk( in apk()
103 ZFile zfile = apk(f, options); in apk()
DApkZFileCreator.java22 import com.android.tools.build.apkzlib.zip.ZFile;
55 private final ZFile zip;
116 ZFile toMerge = closer.register(new ZFile(zip)); in writeZip()
/tools/apkzlib/src/main/java/com/android/tools/build/apkzlib/sign/
DZFileDataSource.java21 import com.android.tools.build.apkzlib.zip.ZFile;
36 private final ZFile file;
55 public ZFileDataSource(@Nonnull ZFile file) { in ZFileDataSource()
66 public ZFileDataSource(@Nonnull ZFile file, long offset, long size) { in ZFileDataSource()
DManifestGenerationExtension.java23 import com.android.tools.build.apkzlib.zip.ZFile;
80 private ZFile zFile;
158 public void register(@Nonnull ZFile zFile) throws IOException { in register()
DSigningExtension.java26 import com.android.tools.build.apkzlib.zip.ZFile;
132 private ZFile zFile;
156 public void register(@Nonnull ZFile zFile) throws NoSuchAlgorithmException, IOException { in register()
/tools/apkzlib/src/main/java/com/android/tools/build/apkzlib/zip/
DCentralDirectory.java184 private final ZFile file;
203 CentralDirectory(@Nonnull ZFile file) { in CentralDirectory()
224 static CentralDirectory makeFromData(@Nonnull ByteBuffer bytes, int count, @Nonnull ZFile file) in makeFromData()
259 @Nonnull ZFile file) { in makeFromEntries()
DCentralDirectoryHeader.java125 private final ZFile file;
143 @Nonnull ZFile zFile) { in CentralDirectoryHeader()
DStoredEntry.java170 private ZFile file;
214 @Nonnull ZFile file, in StoredEntry()
258 if (cdh.getName().endsWith(Character.toString(ZFile.SEPARATOR))) { in StoredEntry()
DZFile.java186 public class ZFile implements Closeable { class
433 public ZFile(@Nonnull File file) throws IOException { in ZFile() method in ZFile
447 public ZFile(@Nonnull File file, @Nonnull ZFileOptions options) throws IOException { in ZFile() method in ZFile
463 public ZFile(@Nonnull File file, @Nonnull ZFileOptions options, boolean readOnly) in ZFile() method in ZFile
1969 public void mergeFrom(@Nonnull ZFile src, @Nonnull Predicate<String> ignoreFilter) in mergeFrom()
/tools/apkzlib/src/test/java/com/android/tools/build/apkzlib/utils/
DApkZFileTestUtils.java22 import com.android.tools.build.apkzlib.zip.ZFile;
115 public static void addAndroidManifest(ZFile zf) throws IOException { in addAndroidManifest()