Class ServerChooser

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible

public class ServerChooser extends JPanel

The ServerChooser class allows the user to select from and edit a list of network servers. Each server has a name and location value (for example, a URL). A property change is used to signal that the user has selected a new server and pressed the connect button. The server property value sent is a ServerTableModel.Entry object from the list of server entries.

Generally, it might be a good idea to save the list of servers after using the chooser, in case the user has edited the server names or locations. The current server list is available from getServerList().

Since:
3.2.0
Author:
Peter Hollemans
See Also:
  • Field Details

  • Constructor Details

    • ServerChooser

      public ServerChooser(List serverList)
      Creates a new chooser with the specified server list.
    • ServerChooser

      public ServerChooser()
      Creates a new empty chooser.
  • Method Details

    • getServerList

      public List getServerList()
      Gets the current list of server entries.
    • main

      public static void main(String[] argv) throws Exception
      Tests this class.
      Parameters:
      argv - the array of command line parameters.
      Throws:
      Exception