Lines Matching refs:path

64                 Path path = fs.getPath(pname);
65 if (!Files.exists(path))
66 throw new RuntimeException("path existence check failed!");
67 while ((path = path.getParent()) != null) {
68 if (!Files.exists(path))
90 // newFileSystem(path...) should not throw exception
231 for (String path : list) {
233 z2zcopy(fs1, fs2, path, 0);
246 for (String path : list) {
248 z2zcopy(fs1, fs2, path, 1);
261 for (String path : list) {
263 z2zcopy(fs1, fs2, path, 2);
279 String path = itr.next();
281 if (Files.exists(fs2.getPath(path))) {
282 z2zmove(fs2, fs3, path);
306 for (String path : files) {
308 checkEqual(fs.getPath(path), fs3.getPath(path));
326 for (String path : files2) {
327 checkEqual(fs.getPath(path), fs4.getPath(path));
340 private static FileSystem newZipFileSystem(Path path, Map<String, ?> env)
344 new URI("jar", path.toUri().toString(), null), env, null);
350 tmp.delete(); // we need a clean path, no file
354 private static void list(Path path, List<String> files, List<String> dirs )
357 if (Files.isDirectory(path)) {
358 try (DirectoryStream<Path> ds = Files.newDirectoryStream(path)) {
362 dirs.add(path.toString());
364 files.add(path.toString());
368 private static void z2zcopy(FileSystem src, FileSystem dst, String path,
372 Path srcPath = src.getPath(path);
373 Path dstPath = dst.getPath(path);
384 path + (path.endsWith("/")?"":"/") + child.getFileName(),
408 private static void z2zmove(FileSystem src, FileSystem dst, String path)
411 Path srcPath = src.getPath(path);
412 Path dstPath = dst.getPath(path);
420 path + (path.endsWith("/")?"":"/") + child.getFileName());
424 //System.out.println("moving..." + path);
432 private static void walk(Path path) throws IOException
435 path,
474 private static void mkdirs(Path path) throws IOException {
475 if (Files.exists(path))
477 path = path.toAbsolutePath();
478 Path parent = path.getParent();
483 Files.createDirectory(path);
486 private static void rmdirs(Path path) throws IOException {
487 while (path != null && path.getNameCount() != 0) {
488 Files.delete(path);
489 path = path.getParent();
651 static void channel(FileSystem fs, Path path)
662 try (SeekableByteChannel sbc = Files.newByteChannel(path)) {
680 try (SeekableByteChannel sbc = fs.provider().newFileChannel(path, read)) {
703 Path path = fs.getPath(name);
704 Path parent = path.getParent();
707 return path;