|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.awt.event.WindowAdapter
Sarj
public class Sarj
The main SARJ application class
| Constructor Summary | |
|---|---|
Sarj()
|
|
| Method Summary | |
|---|---|
static void |
main(java.lang.String[] args)
The main method |
void |
onAction(int actionID)
Called when the Perform button is clicked on the GUI |
void |
onAddAdmin(java.lang.String playerIP)
Called when the user chooses to add a player to the remote administrators list |
void |
onBanPlayer(int playerNumber)
Called when the user chooses to ban a player from the list of currently connected players |
void |
onCommand(java.lang.String command)
Called when a command is sent from the user |
void |
onConnect(java.lang.String address,
int port,
java.lang.String password)
Called when the Connect button is clicked on the GUI |
void |
onConnected()
Called when a connection is successfully established with a server, as a result of calling the connect method of a Connection object. |
void |
onDisconnect()
Called when the Disconnect button is clicked on the GUI |
void |
onDisconnected()
Called when a connection to a server is lost, either gracefully or due to error |
void |
onError(java.lang.String message)
Called when a connection error occurrs |
void |
onExit()
Called when the Exit button is clicked on the GUI, or the main GUI window is closed |
void |
onKickPlayer(int playerNumber)
Called when the user chooses to kick a player from the list of currently connected players |
void |
onRefresh()
Called when the Refresh button is clicked on the GUI, or the refresh timer triggers |
void |
onRemoveAdmin(java.lang.String playerIP)
Called when the user chooses to remove a player from the remote administrators list |
void |
onSetTeam(int playerNumber,
int teamNumber)
Called when the user chooses to assign a connected player to a particular team |
void |
run()
Called when the main execution thread is started by a call to Thread.start() |
void |
Sarj()
Default constructor |
| Methods inherited from class java.awt.event.WindowAdapter |
|---|
windowActivated, windowClosed, windowClosing, windowDeactivated, windowDeiconified, windowGainedFocus, windowIconified, windowLostFocus, windowOpened, windowStateChanged |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Sarj()
| Method Detail |
|---|
public static void main(java.lang.String[] args)
public void Sarj()
public void run()
run in interface java.lang.Runnable
public void onConnect(java.lang.String address,
int port,
java.lang.String password)
onConnect in interface GUIListeneraddress - the address of the Soldat server, in dotted IP format
(X.X.X.X)port - the port number of the Soldat serverpassword - the remote administration password for the serverpublic void onDisconnect()
onDisconnect in interface GUIListenerpublic void onExit()
onExit in interface GUIListenerpublic void onAction(int actionID)
onAction in interface GUIListeneractionID - the ID of the action to be performedpublic void onRefresh()
onRefresh in interface GUIListenerpublic void onCommand(java.lang.String command)
onCommand in interface GUIListenercommand - the command string issued by the userpublic void onKickPlayer(int playerNumber)
onKickPlayer in interface GUIListenerplayerNumber - the unique in-game ID number of the playerpublic void onBanPlayer(int playerNumber)
onBanPlayer in interface GUIListenerplayerNumber - the unique in-game ID number of the playerpublic void onAddAdmin(java.lang.String playerIP)
onAddAdmin in interface GUIListenerplayerIP - the IP address of the playerpublic void onRemoveAdmin(java.lang.String playerIP)
onRemoveAdmin in interface GUIListenerplayerIP - the IP address of the player
public void onSetTeam(int playerNumber,
int teamNumber)
onSetTeam in interface GUIListenerplayerNumber - the unique in-game ID number of the playerteamNumber - the ID of the team to assign the player to, where
1 = alpha, 2 = beta, 3 = charlie and 4 = deltapublic void onConnected()
Connection object.
onConnected in interface ConnectionListenerpublic void onDisconnected()
onDisconnected in interface ConnectionListenerpublic void onError(java.lang.String message)
onError in interface ConnectionListenermessage - the error message
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||