@Override public void mkdir(String dirname) throws IOException { super.mkdir(cwdify(dirname)); }
public void mkdirs(String path) throws IOException { final Deque<String> dirsToMake = new LinkedList<String>(); for (PathComponents current = engine.getPathHelper().getComponents(path); ; current = engine.getPathHelper().getComponents(current.getParent())) { final FileAttributes attrs = statExistence(current.getPath()); if (attrs == null) { dirsToMake.push(current.getPath()); } else if (attrs.getType() != FileMode.Type.DIRECTORY) { throw new SFTPException(current.getPath() + " exists but is not a directory"); } else { break; } } while (!dirsToMake.isEmpty()) { mkdir(dirsToMake.pop()); } }
@Override public void mkdir(String dirname) throws IOException { super.mkdir(cwdify(dirname)); }
@Override public void mkdir(String dirname) throws IOException { super.mkdir(cwdify(dirname)); }
public void mkdirs(String path) throws IOException { final Deque<String> dirsToMake = new LinkedList<String>(); for (PathComponents current = engine.getPathHelper().getComponents(path); ; current = engine.getPathHelper().getComponents(current.getParent())) { final FileAttributes attrs = statExistence(current.getPath()); if (attrs == null) { dirsToMake.push(current.getPath()); } else if (attrs.getType() != FileMode.Type.DIRECTORY) { throw new SFTPException(current.getPath() + " exists but is not a directory"); } else { break; } } while (!dirsToMake.isEmpty()) { mkdir(dirsToMake.pop()); } }
public void mkdirs(String path) throws IOException { final Deque<String> dirsToMake = new LinkedList<String>(); for (PathComponents current = engine.getPathHelper().getComponents(path); ; current = engine.getPathHelper().getComponents(current.getParent())) { final FileAttributes attrs = statExistence(current.getPath()); if (attrs == null) { dirsToMake.push(current.getPath()); } else if (attrs.getType() != FileMode.Type.DIRECTORY) { throw new SFTPException(current.getPath() + " exists but is not a directory"); } else { break; } } while (!dirsToMake.isEmpty()) { mkdir(dirsToMake.pop()); } }