public void move(AcLockingFileWrapper wrapper, String directoryPath) { String oldPath = wrapper.getCurrentPath(); String newPath = JwUtility.joinPath(directoryPath, wrapper.getFilename()); move(oldPath, newPath); wrapper.setDirectoryPath(directoryPath); }
public AcLockingFileWrapper copy(AcLockingFileWrapper wrapper, String directoryPath) { JwFtpClient ftpClient = getFtpClient(); String s = ftpClient.getTextFile(fixPath(wrapper.getCurrentPath())); AcLockingFileWrapper x = wrapper.copy(); x.setDirectoryPath(directoryPath); ftpClient.putTextFile(fixPath(x.getCurrentPath()), s); return x; }
public Reader getFileReader(AcLockingFileWrapper wrapper) { return new StringReader(getFtpClient().getTextFile(fixPath(wrapper.getCurrentPath()))); }
public String readTextFile(AcLockingFileWrapper wrapper) { return getFtpClient().getTextFile(fixPath(wrapper.getCurrentPath())); }
public void writeFile(AcLockingFileWrapper w, String contents) { JwFtpClient ftpClient = getFtpClient(); ftpClient.putTextFile(fixPath(w.getCurrentPath()), contents); }