I'm not sure whether this means that the above command should individually execute either the client or the server (depending on <path_and_filename> , or whether it means that the above command should execute both? My guess is that it means both, because it doesn't really make sense to provide a [<mode>] parameter when running the server.
Question 2 ========== The assignment also says that:
"The program must allow the user to specify the location of the database"
As only the command-line parameter referred to above is allowed, I suppose they'll have to specify the location of the database via the GUI. The nicest way to do this would be by opening up the familiar dialog box used to select a file to open. However the database file could reside on a different machine to the client GUI, so I can't simply open a dialog allowing the user to choose a file on the local machine.
Although I could instead just provide a field where the user types in the path to the file on the server machine, this is not terribly user friendly.
If you type "java -jar runme.jar alone", then the application will run in standalone mode. "java -jar runme.jar server" will start the server only. "java -jar runme.jar" will start the networked client only.
By the way, the questions you are positing in this forum are all good questions. However, I have noticed that most of them have been discussed here before. Try searching the forum for an answer to your question(s), and if you still have uncertainties, post again and other ranchers can help.
Also, I am not trying to be a jerk by suggesting you search the forum... Many times, there is more than one correct solution to the issues you are facing. Searching the forum gives you the opportunity to look at all the sides and then make an educated decision for yourself.
“Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.” - Rich Cook
Joined: Mar 29, 2005
Thanks for your reply Paul ad your suggestion about searching the forum. I'd be interested to hear if you have any thoughts about "Question 2" above. Is it sufficient to enable the user to supply a path to the location of the file on the server, or if not, how can they browse the file system on the server from the client?