redirect output to text file after user input

view story

http://stackoverflow.com – I have created a JNDI java program that gives different kind of output as user specification. For example user can run the program with different parameters as : java MyProg -o row -u username -l uId1,uId2,.... here user can specify options as : -o : for output format(row basis/column basis) -u : connect to server with different user(then program will ask for password) -l : program will show output for given user id(s) Now the thing is for every option I have define a default value(configuration) so its up to user if he want to change the configuration then he will specify the option. So u (HowTos)