/cts/tests/tests/util/src/android/util/cts/ |
StrictJarFileTest.java | 87 StrictJarFile jarFile = new StrictJarFile(fileName); 88 jarFile.close(); 96 StrictJarFile jarFile = new StrictJarFile(fd); 97 jarFile.close(); 103 StrictJarFile jarFile = 105 checkIteration(jarFile); 113 StrictJarFile jarFile = new StrictJarFile(fd); 114 checkIteration(jarFile); 117 private static void checkIteration(StrictJarFile jarFile) throws Exception { 118 Iterator<ZipEntry> it = jarFile.iterator() [all...] |
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/jar/ |
JarFileTest.java | 51 import java.util.jar.JarFile; 160 * java.util.jar.JarFile#JarFile(java.io.File) 164 JarFile jarFile = new JarFile(new File("Wrong.file")); 172 JarFile jarFile = new JarFile(new File(resources, jarName)); 179 * java.util.jar.JarFile#JarFile(java.lang.String [all...] |
JarEntryTest.java | 26 import java.util.jar.JarFile; 37 private JarFile jarFile; 57 jarFile = new JarFile(new File(resources, jarName)); 62 if (jarFile != null) { 63 jarFile.close(); 72 JarEntry newJarEntry = new JarEntry(jarFile.getJarEntry(entryName)); 85 assertNotNull("Jar file is null", jarFile); 86 zipEntry = jarFile.getEntry(entryName) [all...] |
/libcore/luni/src/test/java/libcore/io/ |
ClassPathURLStreamHandlerTest.java | 50 private File jarFile; 56 jarFile = new File(resources, JAR); 66 String fileName = jarFile.getPath(); 72 String fileName = jarFile.getPath(); 105 String fileName = jarFile.getPath(); 113 assertOpenConnectionOk(jarFile, expectedJarRelativeURI, streamHandler); 117 String fileName = jarFile.getPath(); 133 String fileName = jarFile.getPath(); 136 assertOpenConnectionOk(jarFile, ENTRY_IN_ROOT, streamHandler); 137 assertOpenConnectionOk(jarFile, ENTRY_IN_SUBDIR, streamHandler) [all...] |
/libcore/luni/src/test/java/libcore/java/util/jar/ |
OldJarEntryTest.java | 23 import java.util.jar.JarFile; 32 private JarFile jarFile; 41 jarFile = new JarFile(new File(resources, jarName)); 46 if (jarFile != null) { 47 jarFile.close(); 56 JarEntry newJarEntry = new JarEntry(jarFile.getJarEntry(entryName)); 72 assertNotNull("Jar file is null", jarFile); 73 zipEntry = jarFile.getEntry(entryName) [all...] |
OldJarFileTest.java | 23 import java.util.jar.JarFile; 42 new JarFile(new File("Wrong.file")); 48 new JarFile(new File(resources, jarName)); 53 new JarFile("Wrong.file"); 60 new JarFile(fileName); 65 new JarFile("Wrong.file", false); 72 new JarFile(fileName, true); 77 new JarFile(new File("Wrong.file"), true); 83 new JarFile(new File(resources, jarName), false); 88 new JarFile(new File("Wrong.file"), true [all...] |
/libcore/luni/src/main/java/libcore/io/ |
ClassPathURLStreamHandler.java | 30 import java.util.jar.JarFile; 36 * A {@link URLStreamHandler} for a specific class path {@link JarFile}. This class avoids the need 44 private final JarFile jarFile; 47 jarFile = new JarFile(jarFileName); 60 if (findEntryWithDirectoryFallback(jarFile, entryName) != null) { 78 ZipEntry entry = jarFile.getEntry(entryName); 89 jarFile.close(); 93 * Finds an entry with the specified name in the {@code jarFile}. If an exact match isn't found i [all...] |
/libcore/ojluni/src/main/java/sun/net/www/protocol/jar/ |
JarURLConnection.java | 40 import java.util.jar.JarFile; 74 private JarFile jarFile; 88 public JarFile getJarFile() throws IOException { 90 return jarFile; 111 jarFile.close(); 122 jarFile = factory.get(getJarFileURL(), getUseCaches()); 125 * to get the jarFile, and set it as our permission. 128 jarFileURLConnection = factory.getConnection(jarFile); 132 jarEntry = (JarEntry)jarFile.getEntry(entryName) [all...] |
JarFileFactory.java | 33 import java.util.jar.JarFile; 46 private static final HashMap<String, JarFile> fileCache = new HashMap<>(); 49 private static final HashMap<JarFile, URL> urlCache = new HashMap<>(); 59 URLConnection getConnection(JarFile jarFile) throws IOException { 62 u = urlCache.get(jarFile); 70 public JarFile get(URL url) throws IOException { 74 JarFile get(URL url, boolean useCaches) throws IOException { 76 JarFile result; 77 JarFile local_result [all...] |
/external/guava/guava-tests/test/com/google/common/reflect/ |
ClassPathTest.java | 49 import java.util.jar.JarFile; 64 assertThat(resource.getResourceName()).isNotEqualTo(JarFile.MANIFEST_NAME); 65 assertThat(resource.toString()).isNotEqualTo(JarFile.MANIFEST_NAME); 233 File jarFile = File.createTempFile("with_circular_class_path", ".jar"); 235 writeSelfReferencingJarFile(jarFile, "test.txt"); 237 scanner.scan(jarFile.toURI(), ClassPathTest.class.getClassLoader()); 240 jarFile.delete(); 280 File jarFile = new File("base.jar"); 281 assertThat(ClassPath.Scanner.getClassPathFromManifest(jarFile, manifest(""))) 286 File jarFile = new File("base.jar") [all...] |
/cts/tools/vm-tests-tf/targetprep/src/android/core/vm/targetprep/ |
VmTestPreparer.java | 85 File jarFile = new File(ctsBuild.getTestsDir(), JAR_FILE); 86 if (!jarFile.exists()) { 87 CLog.e("Missing jar file %s", jarFile.getPath()); 90 ZipFile zipFile = new ZipFile(jarFile);
|
/external/caliper/caliper/src/main/java/com/google/caliper/runner/ |
JarFinder.java | 37 import java.util.jar.JarFile; 142 JarFile jarFile; 144 jarFile = new JarFile(file); 151 for (URI uri : getClassPathFromManifest(file, jarFile.getManifest())) { 156 jarFile.close(); 169 File jarFile, @Nullable Manifest manifest) { 180 uri = getClassPathEntry(jarFile, path); 199 @VisibleForTesting static URI getClassPathEntry(File jarFile, String path [all...] |
AllocationInstrument.java | 42 import java.util.jar.JarFile; 178 JarFile jarFile = null; 180 jarFile = new JarFile(file); 181 Manifest manifest = jarFile.getManifest(); 188 if (jarFile != null) { 189 jarFile.close(); 198 * on the worker VM's command line with "-javaagent:[jarfile]".
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/net/ |
JarURLConnectionTest.java | 31 import java.util.jar.JarFile; 41 private URL copyAndOpenResourceStream(String jarFile, String inFile) 46 Support_Resources.copyFile(resources, "net", jarFile); 47 File file = new File(resources.toString() + "/net/" + jarFile); 143 File jarFile = File.createTempFile("1+2 3", "test.jar"); 144 jarFile.deleteOnExit(); 145 JarOutputStream out = new JarOutputStream(new FileOutputStream(jarFile)); 151 + jarFile.getAbsolutePath().replaceAll(" ", "%20") + "!/") 166 JarFile jarFile1 = connection.getJarFile(); 172 JarFile jarFile2 = connection.getJarFile() [all...] |
/external/objenesis/tck/src/main/java/org/objenesis/tck/search/ |
ClassEnumerator.java | 23 import java.util.jar.JarFile; 59 JarFile jarFile; 61 jarFile = new JarFile(jarPath); 65 Enumeration<JarEntry> entries = jarFile.entries();
|
/cts/common/host-side/tradefed/src/com/android/compatibility/common/tradefed/testtype/ |
JarHostTest.java | 46 import java.util.jar.JarFile; 84 JarFile jarFile = null; 87 jarFile = new JarFile(file); 88 Enumeration<JarEntry> e = jarFile.entries(); 123 StreamUtil.close(jarFile);
|
/cts/tools/cts-api-coverage/src/com/android/cts/apicoverage/ |
JarTestFinder.java | 32 import java.util.jar.JarFile; 41 try (JarFile jarFile = new JarFile(jarTestFile)) { 42 Enumeration<JarEntry> e = jarFile.entries();
|
/external/testng/src/test/java/test/jarpackages/ |
JarPackagesTest.java | 13 private TestListenerAdapter init(String jarFile) { 19 String finalPath = path + jarFile;
|
/external/icu/android_icu4j/src/main/tests/android/icu/dev/test/serializable/ |
CompatibilityTest.java | 25 import java.util.jar.JarFile; 169 JarFile jarFile = null; 178 jarFile = conn.getJarFile(); 179 Enumeration entries = jarFile.entries(); 187 SerializableTestUtility.copyStreamBytes(jarFile.getInputStream(entry))); 194 if (jarFile != null) { 195 jarFile.close();
|
/external/icu/icu4j/main/tests/core/src/com/ibm/icu/dev/test/serializable/ |
CompatibilityTest.java | 24 import java.util.jar.JarFile; 168 JarFile jarFile = null; 177 jarFile = conn.getJarFile(); 178 Enumeration entries = jarFile.entries(); 186 SerializableTestUtility.copyStreamBytes(jarFile.getInputStream(entry))); 193 if (jarFile != null) { 194 jarFile.close();
|
/frameworks/base/test-runner/src/android/test/ |
ClassPathPackageInfoSource.java | 177 private void findClassesInJar(File jarFile, String pathPrefix, 180 Set<String> entryNames = getJarEntries(jarFile); 247 private Set<String> getJarEntries(File jarFile) 249 Set<String> entryNames = jarFiles.get(jarFile); 252 ZipFile zipFile = new ZipFile(jarFile); 280 jarFiles.put(jarFile, entryNames);
|
/libcore/luni/src/test/java/libcore/java/net/ |
OldJarURLConnectionTest.java | 35 import java.util.jar.JarFile; 46 private URL createContent(String jarFile, String inFile) 51 Support_Resources.copyFile(resources, "net", jarFile); 52 File file = new File(resources.toString() + "/net/" + jarFile); 81 JarFile jf = juc.getJarFile(); 211 File jarFile = File.createTempFile("1+2 3", "test.jar"); 212 jarFile.deleteOnExit(); 213 JarOutputStream out = new JarOutputStream(new FileOutputStream(jarFile)); 219 + jarFile.getAbsolutePath().replaceAll(" ", "%20") + "!/") 235 JarFile jarFile1 = connection.getJarFile() [all...] |
/external/guava/guava/src/com/google/common/reflect/ |
ClassPath.java | 46 import java.util.jar.JarFile; 359 if (!resourceName.equals(JarFile.MANIFEST_NAME)) { 367 JarFile jarFile; 369 jarFile = new JarFile(file); 375 for (URI uri : getClassPathFromManifest(file, jarFile.getManifest())) { 378 Enumeration<JarEntry> entries = jarFile.entries(); 381 if (entry.isDirectory() || entry.getName().equals(JarFile.MANIFEST_NAME)) { 388 jarFile.close() [all...] |
/libcore/luni/src/test/java/libcore/dalvik/system/ |
PathClassLoaderTest.java | 30 import java.util.jar.JarFile; 111 JarFile jarFile = new JarFile(f, true /* verify */, ZipFile.OPEN_READ); 113 JarEntry signedEntry = (JarEntry) jarFile.getEntry(signedEntryName); 119 jarFile.close();
|
/libcore/luni/src/test/java/libcore/java/util/zip/ |
OldAndroidZipStressTest.java | 27 import java.util.jar.JarFile; 39 JarFile jarFile = new JarFile(file); 40 JarEntry je = jarFile.getJarEntry("AndroidManifest.xml"); 46 InputStream is = jarFile.getInputStream(je);
|