|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectgames.strategy.common.delegate.BaseDelegate
public abstract class BaseDelegate
Base class designed to make writing custom delegates simpler. Code common to all delegates is implemented here.
| Field Summary | |
|---|---|
protected IDelegateBridge |
m_bridge
|
protected GameData |
m_data
|
protected java.lang.String |
m_displayName
|
protected java.lang.String |
m_name
|
protected PlayerID |
m_player
|
| Constructor Summary | |
|---|---|
BaseDelegate()
Creates a new instance of the Delegate |
|
| Method Summary | |
|---|---|
void |
end()
Called before the delegate will stop running. |
java.lang.String |
getDisplayName()
|
java.lang.String |
getName()
|
abstract java.lang.Class<? extends IRemote> |
getRemoteType()
If this class implements an interface which inherits from IRemote, returns the class of that interface. |
void |
initialize(java.lang.String name,
java.lang.String displayName)
|
void |
loadState(java.io.Serializable state)
Loads the delegates state |
java.io.Serializable |
saveState()
Returns the state of the Delegate. |
void |
start(IDelegateBridge bridge,
GameData gameData)
Called before the delegate will run. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.lang.String m_name
protected java.lang.String m_displayName
protected PlayerID m_player
protected IDelegateBridge m_bridge
protected GameData m_data
| Constructor Detail |
|---|
public BaseDelegate()
| Method Detail |
|---|
public void initialize(java.lang.String name,
java.lang.String displayName)
initialize in interface IDelegate
public void start(IDelegateBridge bridge,
GameData gameData)
start in interface IDelegatepublic java.lang.String getName()
getName in interface IDelegatepublic java.lang.String getDisplayName()
getDisplayName in interface IDelegatepublic void end()
end in interface IDelegatepublic java.io.Serializable saveState()
saveState in interface IDelegatepublic void loadState(java.io.Serializable state)
loadState in interface IDelegatepublic abstract java.lang.Class<? extends IRemote> getRemoteType()
getRemoteType in interface IDelegate
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||