The main method signature in Java is only a string array.
To prevent out of bound exceptions, you can either try/catch them or simply verify the length first:
PHP Code:
public static void main(String[] argv)
{
if (argv.length != 2)
{
System.out.println("Incorrect command line call of application.");
}
else
{
String sOriginating = argv[0];
String sDestination = argv[1];
// copy stuff here.
}
}