aspose file tools*
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes How GUI asks for the name of the RMI server? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "How GUI asks for the name of the RMI server?" Watch "How GUI asks for the name of the RMI server?" New topic
Author

How GUI asks for the name of the RMI server?

Michael Remijan
Author
Ranch Hand

Joined: May 29, 2002
Posts: 123
    
    5

Right now, if I'm running as an RMI client, the first thing I do is pop up a dialog box and ask the user the name of the RMI server. How have other people approached this? I would have figured to pass the name of the server as a command line arguement instead of the database file name but this doesn't match the assignment's specifications.


Java EE Evangelist — Author, EJB 3 in Action 2nd Edition — Java Community Process Member
Hanna Habashy
Ranch Hand

Joined: Aug 20, 2003
Posts: 532
hi Michael:
I would have figured to pass the name of the server as a command line arguement instead of the

Why do you want to do it on the command line?
In my project, I popup a window for the user to enter the IP address of the server. The server must be running at the time, or an exception will occurs.


SCJD 1.4<br />SCJP 1.4<br />-----------------------------------<br />"With regard to excellence, it is not enough to know, but we must try to have and use it.<br />" Aristotle
Miguel Roque
Ranch Hand

Joined: Oct 24, 2002
Posts: 126
Hi.

When you say the name of the server you mention the name that you have assigned to your server when you call the Registry.rebind(name, ServerClass). If it is it, then there is no need for that. What you need to ask is the server IP or name and the port where the RMI server is running.

In my assignment, my server starts and rebind with the name of FBNServer. When the client connects to the RMI server it has the FBNServer hard coded in it so there is no need to ask for the server name. As told before we only need to know the IP and port of the remote server and this is done using a dialog box.

Miguel
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How GUI asks for the name of the RMI server?