Class JComboServer

All Implemented Interfaces:
ActionListener, ImageObserver, ItemSelectable, MenuContainer, Serializable, EventListener, Accessible, ListDataListener

public class JComboServer extends JComboBox
This class is a user interface component that looks equal to a JComboBox component, but it contains ServerData objects and it is able to show them in last access order.It has methods to add ServerData objects and to retrieve them.
Author:
Jorge Piera Llodra (piera_jor@gva.es)
See Also:
  • invalid reference
    java.swing.JComboBox
  • invalid reference
    es.gva.cit.catalogClient.utils.comboserver.ServerData
  • Serialized Form
  • Constructor Details

    • JComboServer

      public JComboServer()
      Just a simple constructor
    • JComboServer

      public JComboServer(ServerData[] servers)
      A constructor
      Parameters:
      servers - Array with all the rervers to show
  • Method Details

    • getSelectedServer

      public ServerData getSelectedServer()
      This method returns the selected server
      Returns:
      A Server
    • addServer

      public void addServer(ServerData server)
      This method adds a new Server in order
      Parameters:
      server - New Server
    • getAllServers

      public ServerData[] getAllServers()
      This method returns an array with all the servers that the combo contains
      Returns:
      An array of servers
    • setServerList

      public void setServerList(ServerData[] servers)
      It adds a server list
      Parameters:
      servers - Array with servers
    • setServersOrder

      public void setServersOrder()
      This method order all the servers in the combo