/libcore/tzdata/shared2/src/test/libcore/tzdata/shared2/ |
D | FileUtilsTest.java | 54 File dir = createTempDir(); in testDeleteRecursive() local 55 File file1 = createRegularFile(dir, "file1"); in testDeleteRecursive() 56 File file2 = createRegularFile(dir, "file2"); in testDeleteRecursive() 57 File symLink1 = createSymlink(file1, dir, "symLink1"); in testDeleteRecursive() 58 File subDir = createDir(dir, "subDir"); in testDeleteRecursive() 61 File symLink2 = createSymlink(file1, dir, "symLink2"); in testDeleteRecursive() 69 File[] filesToDelete = { dir, file1, file2, symLink1, subDir, file3, file4, symLink2, in testDeleteRecursive() 75 FileUtils.deleteRecursive(dir); in testDeleteRecursive() 81 File dir = createTempDir(); in testIsSymlink() local 82 File subDir = createDir(dir, "subDir"); in testIsSymlink() [all …]
|
D | TimeZoneDistroTest.java | 74 File dir = createTempDir(); in testExtractZipSafely_goodZip() local 75 File targetDir = new File(dir, "target"); in testExtractZipSafely_goodZip() 107 File dir = createTempDir(); in doExtractZipFails() local 108 File targetDir = new File(dir, "target"); in doExtractZipFails() 147 for (File dir : dirs) { in assertDirsExist() 148 assertTrue(dir + " directory expected to exist", dir.exists() && dir.isDirectory()); in assertDirsExist()
|
/libcore/ojluni/src/test/java/nio/file/ |
D | TestUtil.java | 37 Path dir = FileSystems.getDefault().getPath(where); in createTemporaryDirectory() local 38 return Files.createTempDirectory(dir, "name"); in createTemporaryDirectory() 45 static public void removeAll(Path dir) throws IOException { in removeAll() argument 46 Files.walkFileTree(dir, new FileVisitor<Path>() { in removeAll() 48 public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs) { in removeAll() 61 public FileVisitResult postVisitDirectory(Path dir, IOException exc) { in removeAll() 63 Files.delete(dir); in removeAll() 65 System.err.format("Unable to delete %s: %s\n", dir, x); in removeAll() 90 static public Path createDirectoryWithLongPath(Path dir) in createDirectoryWithLongPath() argument 99 dir = dir.resolve(name).resolve("."); in createDirectoryWithLongPath() [all …]
|
/libcore/ojluni/src/test/java/nio/file/attribute/ |
D | BasicFileAttributeViewTest.java | 50 static void checkAttributesOfDirectory(Path dir) in checkAttributesOfDirectory() argument 53 BasicFileAttributes attrs = Files.readAttributes(dir, BasicFileAttributes.class); in checkAttributesOfDirectory() 60 File f = new File(dir.toString()); in checkAttributesOfDirectory() 65 static void checkAttributesOfFile(Path dir, Path file) in checkAttributesOfFile() argument 84 BasicFileAttributes dirAttrs = Files.readAttributes(dir, BasicFileAttributes.class); in checkAttributesOfFile() 107 static void attributeReadWriteTests(Path dir) in attributeReadWriteTests() argument 111 Path file = dir.resolve("foo"); in attributeReadWriteTests() 117 checkAttributesOfDirectory(dir); in attributeReadWriteTests() 118 checkAttributesOfFile(dir, file); in attributeReadWriteTests() 121 Path link = dir.resolve("link"); in attributeReadWriteTests() [all …]
|
D | PosixFileAttributeViewTest.java | 131 static void permissionTests(Path dir) in permissionTests() argument 137 Path file = dir.resolve("foo"); in permissionTests() 179 if (TestUtil.supportsLinks(dir)) { in permissionTests() 180 Path link = dir.resolve("link"); in permissionTests() 203 static void createTests(Path dir) in createTests() argument 208 Path file = dir.resolve("foo"); in createTests() 239 static void ownerTests(Path dir) in ownerTests() argument 244 Path file = dir.resolve("gus"); in ownerTests() 275 static void lookupPrincipalTests(Path dir) in lookupPrincipalTests() argument 280 UserPrincipalLookupService lookupService = dir.getFileSystem() in lookupPrincipalTests() [all …]
|
D | BasicFileAttributeViewCreationTimeTest.java | 127 Path dir = TestUtil.createTemporaryDirectory(); in main() local 129 test(dir); in main() 131 TestUtil.removeAll(dir); in main()
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/ |
D | FileTest.java | 41 private static void deleteTempFolder(File dir) { in deleteTempFolder() argument 42 String files[] = dir.list(); in deleteTempFolder() 45 File f = new File(dir, files[i]); in deleteTempFolder() 53 dir.delete(); in deleteTempFolder() 363 File dir = new File(base, String.valueOf(numDir)); in test_createNewFile() local 368 if (dir.exists()) { in test_createNewFile() 370 dir = new File(base, String.valueOf(numDir)); in test_createNewFile() 380 File f1 = new File(dir, "tempfile.tst"); in test_createNewFile() 387 dir.mkdir(); in test_createNewFile() 389 File f1 = new File(dir, "tempfile.tst"); in test_createNewFile() [all …]
|
/libcore/ojluni/src/main/java/java/nio/file/ |
D | TempFileHelper.java | 57 private static Path generatePath(String prefix, String suffix, Path dir) { in generatePath() argument 60 Path name = dir.getFileSystem().getPath(prefix + Long.toString(n) + suffix); in generatePath() 64 return dir.resolve(name); in generatePath() 80 private static Path create(Path dir, in create() argument 91 if (dir == null) in create() 92 dir = tmpdir; in create() 96 if (isPosix && (dir.getFileSystem() == FileSystems.getDefault())) { in create() 127 f = generatePath(prefix, suffix, dir); in create() 142 if (dir == tmpdir && sm != null) in create() 155 static Path createTempFile(Path dir, in createTempFile() argument [all …]
|
D | SimpleFileVisitor.java | 57 public FileVisitResult preVisitDirectory(T dir, BasicFileAttributes attrs) in preVisitDirectory() argument 60 Objects.requireNonNull(dir); in preVisitDirectory() 104 public FileVisitResult postVisitDirectory(T dir, IOException exc) in postVisitDirectory() argument 107 Objects.requireNonNull(dir); in postVisitDirectory()
|
D | Files.java | 454 public static DirectoryStream<Path> newDirectoryStream(Path dir) 457 return provider(dir).newDirectoryStream(dir, AcceptAllFilter.FILTER); 509 public static DirectoryStream<Path> newDirectoryStream(Path dir, String glob) 514 return newDirectoryStream(dir); 517 FileSystem fs = dir.getFileSystem(); 525 return fs.provider().newDirectoryStream(dir, filter); 585 public static DirectoryStream<Path> newDirectoryStream(Path dir, 589 return provider(dir).newDirectoryStream(dir, filter); 671 public static Path createDirectory(Path dir, FileAttribute<?>... attrs) 674 provider(dir).createDirectory(dir, attrs); [all …]
|
D | DirectoryNotEmptyException.java | 46 public DirectoryNotEmptyException(String dir) { in DirectoryNotEmptyException() argument 47 super(dir); in DirectoryNotEmptyException()
|
D | FileTreeWalker.java | 68 private final Path dir; field in FileTreeWalker.DirectoryNode 74 DirectoryNode(Path dir, Object key, DirectoryStream<Path> stream) { in DirectoryNode() argument 75 this.dir = dir; in DirectoryNode() 82 return dir; in directory() 236 private boolean wouldLoop(Path dir, Object key) { in wouldLoop() argument 248 if (Files.isSameFile(dir, ancestor.directory())) { in wouldLoop()
|
D | FileVisitor.java | 119 FileVisitResult preVisitDirectory(T dir, BasicFileAttributes attrs) in preVisitDirectory() argument 175 FileVisitResult postVisitDirectory(T dir, IOException exc) in postVisitDirectory() argument
|
/libcore/luni/src/test/java/libcore/java/io/ |
D | OldFileTest.java | 49 private void deleteTempFolder(File dir) { in deleteTempFolder() argument 50 String files[] = dir.list(); in deleteTempFolder() 52 File f = new File(dir, files[i]); in deleteTempFolder() 59 dir.delete(); in deleteTempFolder() 138 File dir = new File(base, platformId); in test_renameToLjava_io_File() local 139 dir.mkdir(); in test_renameToLjava_io_File() 140 File f = new File(dir, "xxx.xxx"); in test_renameToLjava_io_File() 150 File dir = new File(""); // current directory in test_toURL3() local 151 String newDirURL = dir.toURL().toString(); in test_toURL3() 157 File dir = new File(cts + "/hello"); in test_deleteOnExit() local [all …]
|
D | OldFileWriterTest.java | 40 File dir = new File(System.getProperty("java.io.tmpdir")); in test_ConstructorLjava_io_File_IOException() local 43 fw = new FileWriter(dir); in test_ConstructorLjava_io_File_IOException() 51 File dir = new File(System.getProperty("java.io.tmpdir")); in test_ConstructorLjava_io_FileZ_IOException() local 54 fw = new FileWriter(dir, true); in test_ConstructorLjava_io_FileZ_IOException()
|
/libcore/ojluni/src/main/java/java/util/prefs/ |
D | FileSystemPreferences.java | 256 private final File dir; field in FileSystemPreferences 466 dir = (user ? userRootDir: systemRootDir); in FileSystemPreferences() 467 prefsFile = new File(dir, "prefs.xml"); in FileSystemPreferences() 468 tmpFile = new File(dir, "prefs.tmp"); in FileSystemPreferences() 476 this.dir = new File(path); in FileSystemPreferences() 477 prefsFile = new File(dir, "prefs.xml"); in FileSystemPreferences() 478 tmpFile = new File(dir, "prefs.tmp"); in FileSystemPreferences() 479 newNode = !dir.exists(); in FileSystemPreferences() 504 dir = new File(parent.dir, dirName(name)); in FileSystemPreferences() 505 prefsFile = new File(dir, "prefs.xml"); in FileSystemPreferences() [all …]
|
/libcore/ojluni/src/main/java/sun/nio/fs/ |
D | LinuxFileStore.java | 85 byte[] dir = path.asByteArray(); in findMountEntry() 87 if (Arrays.equals(dir, entry.dir())) in findMountEntry() 143 UnixPath dir = new UnixPath(file().getFileSystem(), entry().dir()); in supportsFileAttributeView() local 144 xattrEnabled = isExtendedAttributesEnabled(dir); in supportsFileAttributeView()
|
D | UnixDirectoryStream.java | 46 private final UnixPath dir; field in UnixDirectoryStream 70 UnixDirectoryStream(UnixPath dir, long dp, DirectoryStream.Filter<? super Path> filter) { in UnixDirectoryStream() argument 71 this.dir = dir; in UnixDirectoryStream() 80 return dir; in directory() 183 IOException ioe = x.asIOException(dir); in readNextEntry() 197 Path entry = dir.resolve(nameAsBytes); in readNextEntry()
|
D | UnixMountEntry.java | 34 private byte[] dir; // directory (mount point) field in UnixMountEntry 55 byte[] dir() { in dir() method in UnixMountEntry 56 return dir; in dir()
|
D | UnixFileSystemProvider.java | 62 abstract UnixFileSystem newFileSystem(String dir); in newFileSystem() argument 379 UnixPath dir = UnixPath.toUnixPath(obj); in createDirectory() local 380 dir.checkWrite(); in createDirectory() 384 mkdir(dir, mode); in createDirectory() 387 throw new FileAlreadyExistsException(dir.toString()); in createDirectory() 388 x.rethrowAsIOException(dir); in createDirectory() 397 UnixPath dir = UnixPath.toUnixPath(obj); in newDirectoryStream() local 398 dir.checkRead(); in newDirectoryStream() 406 long ptr = opendir(dir); in newDirectoryStream() 407 return new UnixDirectoryStream(dir, ptr, filter); in newDirectoryStream() [all …]
|
D | LinuxWatchService.java | 93 WatchKey register(Path dir, in register() argument 99 return poller.register(dir, events, modifiers); in register() 117 LinuxWatchKey(UnixPath dir, LinuxWatchService watcher, int ifd, int wd) { in LinuxWatchKey() argument 118 super(dir, watcher); in LinuxWatchKey() 226 UnixPath dir = (UnixPath)obj; in implRegister() local 258 attrs = UnixFileAttributes.get(dir, true); in implRegister() 260 return x.asIOException(dir); in implRegister() 263 return new NotDirectoryException(dir.getPathForExceptionMessage()); in implRegister() 270 NativeBuffers.asNativeBuffer(dir.getByteArrayForSysCalls()); in implRegister() 280 return x.asIOException(dir); in implRegister() [all …]
|
D | AbstractWatchKey.java | 57 private final Path dir; field in AbstractWatchKey 69 protected AbstractWatchKey(Path dir, AbstractWatchService watcher) { in AbstractWatchKey() argument 71 this.dir = dir; in AbstractWatchKey() 86 return dir; in watchable()
|
/libcore/ojluni/src/main/java/sun/misc/ |
D | MetaIndex.java | 153 public static synchronized void registerDirectory(File dir) { in registerDirectory() argument 163 File indexFile = new File(dir, "meta-index"); in registerDirectory() 174 dir = dir.getCanonicalFile(); in registerDirectory() 191 map.put(new File(dir, curJarName), in registerDirectory() 216 map.put(new File(dir, curJarName), in registerDirectory()
|
/libcore/ojluni/src/main/java/java/io/ |
D | UnixFileSystem.java | 151 String dir = null; in canonicalize() local 157 dir = parentOrNull(path); in canonicalize() 158 if (dir != null) { in canonicalize() 159 resDir = javaHomePrefixCache.get(dir); in canonicalize() 162 String filename = path.substring(1 + dir.length()); in canonicalize() 164 cache.put(dir + slash + filename, res); in canonicalize() 173 dir != null && dir.startsWith(javaHome)) { in canonicalize() 179 if (resDir != null && resDir.equals(dir)) { in canonicalize() 182 javaHomePrefixCache.put(dir, resDir); in canonicalize()
|
/libcore/ |
D | NativeCode.mk | 36 define include-core-native-dir 50 define include-openjdk-native-dir 69 $(foreach dir, \ 71 $(eval $(call include-openjdk-native-dir,$(dir)))) 74 $(foreach dir, \ 76 $(eval $(call include-core-native-dir,$(dir))))
|