import com.jcraft.jsch.*; public class App { public static void main(String args[]) { JSch jsch = new JSch(); Session session = null; try { sess
Do a copy of the remote file and then delete it
ChannelSftp.get("remotefile.txt", "localfile.txt"); ChannelSftp.rm("remotefile.txt")