|
|
For instance, I want to do something like this.
File src = new File("C:\\src.txt");
File dst = new File("C:\\dst.txt");
FileManager.copyFile(src, dst);
However, I want copyFile to run in it's own thread so my program can continue functioning. I know workarounds using temporary instantiation such as... (assuming FileManager extends Thread);
command c = "copy";
new FileManager(c, src, dest).start();
but doing it that way is clumsy and requires more code and more room for error (and variables I won't use). Any help?