Package marauroa.server.game.dbcommand
Class LoadAllCharactersCommand
java.lang.Object
marauroa.server.db.command.AbstractDBCommand
marauroa.server.game.dbcommand.DBCommandWithCallback
marauroa.server.game.dbcommand.LoadAllCharactersCommand
- All Implemented Interfaces:
DBCommand
asynchronously loads a list of all character for a user.
- Author:
- hendrik
-
Field Summary
Fields inherited from class marauroa.server.game.dbcommand.DBCommandWithCallback
callback
-
Constructor Summary
ConstructorDescriptionLoadAllCharactersCommand(String username)
Creates a new LoadCharacterCommandLoadAllCharactersCommand(String username, DelayedEventHandler callback, int clientid, Channel channel, int protocolVersion)
Creates a new LoadCharacterCommand -
Method Summary
Modifier and TypeMethodDescriptionvoid
execute(DBTransaction transaction)
processes the database request.Gets the characters maptoString()
returns a string suitable for debug output of this DBCommand.Methods inherited from class marauroa.server.game.dbcommand.DBCommandWithCallback
getChannel, getClientid, getProtocolVersion, invokeCallback
Methods inherited from class marauroa.server.db.command.AbstractDBCommand
getEnqueueTime, getException, setEnqueueTime, setException
-
Constructor Details
-
LoadAllCharactersCommand
Creates a new LoadCharacterCommand- Parameters:
username
- name of account
-
LoadAllCharactersCommand
public LoadAllCharactersCommand(String username, DelayedEventHandler callback, int clientid, Channel channel, int protocolVersion)Creates a new LoadCharacterCommand- Parameters:
username
- name of accountcallback
- DelayedEventHandlerclientid
- optional parameter available to the callbackchannel
- optional parameter available to the callbackprotocolVersion
- version of protocol
-
-
Method Details
-
execute
Description copied from class:AbstractDBCommand
processes the database request.- Specified by:
execute
in interfaceDBCommand
- Specified by:
execute
in classAbstractDBCommand
- Parameters:
transaction
- DBTransaction- Throws:
SQLException
- in case of an database errorIOException
- in case of an input/output error
-
getCharacters
Gets the characters map- Returns:
- characters
-
toString
returns a string suitable for debug output of this DBCommand.
-