|
Crossfire JXClient, Trunk
R20561
|
Maintains currently running script processes. More...
Collaboration diagram for com.realtime.crossfire.jxclient.scripts.ScriptManager:Public Member Functions | |
| Set< ScriptProcess > | getScripts (@NotNull final String partialScriptName) |
| Returns all running scripts matching a given (partial) name or a script ID. More... | |
| boolean | hasScripts () |
| Returns whether at least one script is running. More... | |
| void | newScript (@NotNull final String command) |
| Creates a new script instance. More... | |
| ScriptManager (@NotNull final CommandQueue commandQueue, @NotNull final CrossfireServerConnection crossfireServerConnection, @NotNull final Stats stats, @NotNull final FloorView floorView, @NotNull final ItemSet itemSet, @NotNull final Iterable< Spell > spellsManager, @NotNull final MapUpdaterState mapUpdaterState, @NotNull final SkillSet skillSet) | |
| Creates a new instance. More... | |
Private Member Functions | |
| Set< ScriptProcess > | getScriptByScriptId (final int scriptId) |
| Returns all running scripts matching a given script ID. More... | |
| Set< ScriptProcess > | getScriptsByName (@NotNull final CharSequence partialScriptName) |
| Returns all running scripts matching a given (partial) name. More... | |
Private Attributes | |
| final CommandQueue | commandQueue |
| The CommandQueue for sending commands. More... | |
| final CrossfireServerConnection | crossfireServerConnection |
| The CrossfireServerConnection instance. More... | |
| final FloorView | floorView |
| The FloorView to use. More... | |
| final ItemSet | itemSet |
| The ItemSet instance to use. More... | |
| final MapUpdaterState | mapUpdaterState |
| The MapUpdaterState instance to use. More... | |
| int | nextScriptId = 1 |
| The script ID for the next created script. More... | |
| final Collection< ScriptProcess > | scriptProcesses = new CopyOnWriteArraySet<>() |
| All running ScriptProcesses. More... | |
| final SkillSet | skillSet |
| The SkillSet for looking up skill names. More... | |
| final Iterable< Spell > | spellsManager |
| The spells manager instance to use. More... | |
| final Stats | stats |
| The Stats instance to watch. More... | |
Maintains currently running script processes.
Definition at line 45 of file ScriptManager.java.
| com.realtime.crossfire.jxclient.scripts.ScriptManager.ScriptManager | ( | @NotNull final CommandQueue | commandQueue, |
| @NotNull final CrossfireServerConnection | crossfireServerConnection, | ||
| @NotNull final Stats | stats, | ||
| @NotNull final FloorView | floorView, | ||
| @NotNull final ItemSet | itemSet, | ||
| @NotNull final Iterable< Spell > | spellsManager, | ||
| @NotNull final MapUpdaterState | mapUpdaterState, | ||
| @NotNull final SkillSet | skillSet | ||
| ) |
Creates a new instance.
| commandQueue | the command queue for sending commands |
| crossfireServerConnection | the connection instance |
| stats | the stats instance to watch |
| floorView | the floor view to use |
| itemSet | the item set instance to use |
| spellsManager | the spells manager instance to use |
| mapUpdaterState | the map updater state instance to use |
| skillSet | the skill set for looking up skill names |
Definition at line 117 of file ScriptManager.java.
References com.realtime.crossfire.jxclient.scripts.ScriptManager.commandQueue, com.realtime.crossfire.jxclient.scripts.ScriptManager.crossfireServerConnection, com.realtime.crossfire.jxclient.scripts.ScriptManager.floorView, com.realtime.crossfire.jxclient.scripts.ScriptManager.itemSet, com.realtime.crossfire.jxclient.scripts.ScriptManager.mapUpdaterState, com.realtime.crossfire.jxclient.scripts.ScriptManager.skillSet, com.realtime.crossfire.jxclient.scripts.ScriptManager.spellsManager, and com.realtime.crossfire.jxclient.scripts.ScriptManager.stats.
|
private |
Returns all running scripts matching a given script ID.
| scriptId | the script ID |
Definition at line 176 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.getScripts().
Here is the caller graph for this function:| Set<ScriptProcess> com.realtime.crossfire.jxclient.scripts.ScriptManager.getScripts | ( | @NotNull final String | partialScriptName | ) |
Returns all running scripts matching a given (partial) name or a script ID.
| partialScriptName | the partial name or a script ID to match against; an empty string matches all scripts |
Definition at line 162 of file ScriptManager.java.
References com.realtime.crossfire.jxclient.scripts.ScriptManager.getScriptByScriptId(), and com.realtime.crossfire.jxclient.scripts.ScriptManager.getScriptsByName().
Referenced by com.realtime.crossfire.jxclient.commands.ScriptkillallCommand.execute(), com.realtime.crossfire.jxclient.commands.ScriptkillCommand.execute(), com.realtime.crossfire.jxclient.commands.ScriptsCommand.execute(), and com.realtime.crossfire.jxclient.commands.ScripttellCommand.execute().
Here is the call graph for this function:
Here is the caller graph for this function:
|
private |
Returns all running scripts matching a given (partial) name.
| partialScriptName | the partial script name; an empty string matches all scripts |
Definition at line 194 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.getScripts().
Here is the caller graph for this function:| boolean com.realtime.crossfire.jxclient.scripts.ScriptManager.hasScripts | ( | ) |
Returns whether at least one script is running.
Definition at line 202 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.commands.ScriptkillallCommand.execute(), com.realtime.crossfire.jxclient.commands.ScriptkillCommand.execute(), com.realtime.crossfire.jxclient.commands.ScriptsCommand.execute(), and com.realtime.crossfire.jxclient.commands.ScripttellCommand.execute().
Here is the caller graph for this function:| void com.realtime.crossfire.jxclient.scripts.ScriptManager.newScript | ( | @NotNull final String | command | ) |
Creates a new script instance.
| command | the script command including arguments |
Definition at line 132 of file ScriptManager.java.
References com.realtime.crossfire.jxclient.scripts.DefaultScriptProcess.addScriptProcessListener(), com.realtime.crossfire.jxclient.server.crossfire.CrossfireServerConnection.drawInfo(), com.realtime.crossfire.jxclient.server.crossfire.CrossfireDrawinfoListener.NDI_BLACK, and com.realtime.crossfire.jxclient.server.crossfire.CrossfireDrawinfoListener.NDI_RED.
Referenced by com.realtime.crossfire.jxclient.commands.ScriptCommand.execute().
Here is the call graph for this function:
Here is the caller graph for this function:
|
private |
The CommandQueue for sending commands.
Definition at line 51 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.ScriptManager().
|
private |
The CrossfireServerConnection instance.
Definition at line 57 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.ScriptManager().
|
private |
The FloorView to use.
Definition at line 69 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.ScriptManager().
|
private |
The ItemSet instance to use.
Definition at line 75 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.ScriptManager().
|
private |
The MapUpdaterState instance to use.
Definition at line 87 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.ScriptManager().
|
private |
The script ID for the next created script.
Definition at line 104 of file ScriptManager.java.
|
private |
All running ScriptProcesses.
Definition at line 99 of file ScriptManager.java.
|
private |
The SkillSet for looking up skill names.
Definition at line 93 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.ScriptManager().
|
private |
The spells manager instance to use.
Definition at line 81 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.ScriptManager().
|
private |
The Stats instance to watch.
Definition at line 63 of file ScriptManager.java.
Referenced by com.realtime.crossfire.jxclient.scripts.ScriptManager.ScriptManager().