test/tools/javac/api/T6838467.java

changeset 923
6970d9fb8e02
parent 882
3d45cc94ee0f
child 1013
8eb952f43b11
equal deleted inserted replaced
916:cb9493a80341 923:6970d9fb8e02
176 StandardJavaFileManager fm = createFileManager(fk == FileKind.ZIP); 176 StandardJavaFileManager fm = createFileManager(fk == FileKind.ZIP);
177 fm.setLocation(StandardLocation.CLASS_PATH, Arrays.asList(classpath)); 177 fm.setLocation(StandardLocation.CLASS_PATH, Arrays.asList(classpath));
178 return fm; 178 return fm;
179 } 179 }
180 180
181 JavacFileManager createFileManager(boolean useOptimedZipIndex) { 181 JavacFileManager createFileManager(boolean useOptimizedZip) {
182 Context ctx = new Context(); 182 Context ctx = new Context();
183 if (useOptimedZipIndex) { 183 Options options = Options.instance(ctx);
184 Options options = Options.instance(ctx); 184 options.put("useOptimizedZip", Boolean.toString(useOptimizedZip));
185 options.put("useOptimizedZip", "true");
186 }
187 return new JavacFileManager(ctx, false, null); 185 return new JavacFileManager(ctx, false, null);
188 } 186 }
189 187
190 // create a directory containing a given set of paths 188 // create a directory containing a given set of paths
191 void createTestDir(File dir, String[] paths) throws IOException { 189 void createTestDir(File dir, String[] paths) throws IOException {

mercurial