public class NotifyWebServerViaFile extends java.lang.Object implements INotifyWebServer
Modifier and Type | Field and Description |
---|---|
private boolean |
active |
private java.io.File |
flagFile |
private java.lang.String |
flagFilename |
private static java.util.logging.Logger |
LOGGER |
private java.io.PrintWriter |
out |
ALL_CLIENTS_CONNECTED, GAME_STARTUP_COMPLETED, GAME_STARTUP_FAILED
Constructor and Description |
---|
NotifyWebServerViaFile(java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
void |
allClientsConnected() |
private void |
createFlagfile() |
void |
gameStartupCompleted() |
void |
gameStartupFailed(java.lang.String reason) |
void |
gotClient(java.lang.String playerName,
boolean remote) |
boolean |
isActive() |
void |
readyToAcceptClients() |
private void |
removeFlagfile() |
void |
serverStoppedRunning() |
private static final java.util.logging.Logger LOGGER
private final java.lang.String flagFilename
private java.io.PrintWriter out
private java.io.File flagFile
private final boolean active
public boolean isActive()
isActive
in interface INotifyWebServer
public void readyToAcceptClients()
readyToAcceptClients
in interface INotifyWebServer
public void gotClient(java.lang.String playerName, boolean remote)
gotClient
in interface INotifyWebServer
public void allClientsConnected()
allClientsConnected
in interface INotifyWebServer
public void gameStartupCompleted()
gameStartupCompleted
in interface INotifyWebServer
public void gameStartupFailed(java.lang.String reason)
gameStartupFailed
in interface INotifyWebServer
public void serverStoppedRunning()
serverStoppedRunning
in interface INotifyWebServer
private void createFlagfile()
private void removeFlagfile()