Package net.sf.freecol.server.model
Class TimedSession
- java.lang.Object
- 
- net.sf.freecol.server.model.Session
- 
- net.sf.freecol.server.model.TimedSession
 
 
- 
- Direct Known Subclasses:
- DiplomacySession,- NativeDemandSession
 
 public abstract class TimedSession extends Session Root class for timed sessions.
- 
- 
Constructor SummaryConstructors Modifier Constructor Description protectedTimedSession(java.lang.String key, long timeout)Protected constructor, we only really instantiate specific types of transactions.
 - 
Method SummaryAll Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voidcancel()Cancel the timer task.protected abstract booleancomplete(boolean result)Complete this task with the given result.booleancomplete(ChangeSet cs)All transaction types must implement a completion action.- 
Methods inherited from class net.sf.freecol.server.model.SessionclearAll, completeAll, findSession, getKey, lookup, lookup, lookup, makeSessionKey, makeSessionKey, register
 
- 
 
- 
- 
- 
Method Detail- 
completeprotected abstract boolean complete(boolean result) Complete this task with the given result. By default this will be called (with value == false) when the timer expires.- Parameters:
- result- The result to complete the session with.
- Returns:
- The result of the session.
 
 - 
cancelprotected void cancel() Cancel the timer task.
 - 
completepublic boolean complete(ChangeSet cs) All transaction types must implement a completion action. This is called by the controller at the end of turn to complete any sessions that have not yet completed, or if the controller gets the required response to complete the session.
 
- 
 
-