Class ComboServerController
java.lang.Object
org.gvsig.utils.swing.jcomboServer.ComboServerController
This class is a controller for a JComboBox component. 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:
- gvSIG Team
-
Constructor Summary
ConstructorsConstructorDescriptionComboServerController(JComboBox combo) ComboServerController(JComboBox combo, ServerData[] servers) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddServer(ServerData server) This method adds a new Server in orderThis method returns an array with all the servers that the combo containsgetCombo()getItemAt(int i) intgetModel()This method returns the selected servervoidsetModel(ComboBoxModel model) voidsetServerList(ServerData[] servers) It adds a server listvoidThis method order all the servers in the combo
-
Constructor Details
-
ComboServerController
-
ComboServerController
-
-
Method Details
-
getCombo
-
getSelectedServer
This method returns the selected server- Returns:
- A Server
-
addServer
This method adds a new Server in order- Parameters:
server- New Server
-
getAllServers
This method returns an array with all the servers that the combo contains- Returns:
- An array of servers
-
setServerList
It adds a server list- Parameters:
servers- Array with servers
-
setServersOrder
public void setServersOrder()This method order all the servers in the combo -
setModel
-
getModel
-
getItemCount
public int getItemCount() -
getItemAt
-