Changes the working directory on the remote server.
9596979899100101102103104105
sftp.mkdir("j2ssh"); } catch (IOException ex) { } // Change directory sftp.cd("j2ssh"); System.out.println(sftp.pwd()); // Change the mode sftp.chmod(0777, "j2ssh"); sftp.lcd("c:/"); // Upload a file