Nope. The copy command is taking care of that itself. Try compiling this C++ program:
#include <iostream.h>
void main( int argc, char *argv[] )
{
cout << "You supplied " << (argc-1) <<
" arguments (argc is " << argc << "):" << endl;
for( int i = 0; i < argc; i++ )
cout << "argv[" << i << "] => " << argv[i] << endl;
}
and this Java program:
public class CmdLine
{
public static void main( String args[] )
{
System.out.println( "You supplied " + args.length +
" arguments (args.Length is " +
args.length + "):" );
for( int i = 0; i < args.length; i++ )
System.out.println( "args[" + i + "] => " + args[i] );
}
}
Now try running the C++ program with the command line *.* and the Java version with the same command line. The C++ program will have this output:
You supplied 1 arguments (argc is 2):
argv[0] => D:\code\cmdline.exe
argv[1] => *.*
but the Java program will automatically expand out the *.* to match all the files in the current directory, like so:
You supplied 196 arguments (args.Length is 196):
args[0] => AddressInfo.java
args[1] => AddressInfo2.java
args[2] => AddressInfo3.java
. . .