1-When I start the application , the mode is "a simple mode flag", this talks about that he mode is a zero or a one.
2-When I must choose the dabase file in local mode , I have used a JFileChooser , but my question is , when I have to choose the database fil in other server (modo networked) , Can I use the JfileCooser too? , I do not know very clearly , since I must this.�
When I start the application , the mode is "a simple mode flag", this talks about that he mode is a zero or a one.
The mode flag is the "server" command line option, the "alone" command line option, or the non-existance of any command line option.
That is, the command line option is used as a flag to set the mode of the application.
When I must choose the dabase file in local mode , I have used a JFileChooser , but my question is , when I have to choose the database fil in other server (modo networked) , Can I use the JfileCooser too? , I do not know very clearly , since I must this.
You can use a JFileChooser for the server. You might like to think about creating a server GUI which will allow the server administrator to
define which port RMI will be using
Specify where the database file is
shutdown the server
Personally, I really dislike the idea of having a server application which requires a GUI to be manually run to start - I think a server application should be running as a daemon process in Unix, or as service in Windows. However for the purposes of the assignment I can see that having a server GUI will make it easier for the assessor to start/stop your server.
Regards, Andrew [ March 18, 2005: Message edited by: Andrew Monkhouse ]
this mean that I choose the database file in a server ??? , I thought that when I connect in mode server , I used the JFilechooser in a client , but I don,t know if you want say me that when I conect in mode server I should to use the JFileChooser in a server , this mean that the database file in mode server dont choose the user if no the person that start the server ???
When the administrator starts the Server application, you must allow them to choose the location of the database (where it physically exists on the local hard drives).
When a user starts the Client application, you must allow them to specify the location of the database (the IP address or hostname of the server, and possibly the port number being used).
It is important to realise that the location of the database from a client perspective is not a physical file on the hard drive. The physical file may be on a different computer and possibly even on a different operating system. So from a client perspective the location of the database is just the information on how to connect to the server.
Note that all this information should be persisted between each run of the application.