Interface Command
- All Known Implementing Classes:
AcceptCommand
,AdminCommand
,AfkCommand
,ApplyCommand
,AskCommand
,BogusCommand
,BowCommand
,BuyCommand
,ChangeMasterCommand
,ChatCommand
,ClearCommand
,CloseCommand
,CommunicationCommand
,ConditionCommand
,CreateChatCommand
,CreateGuildCommand
,CryCommand
,CurtseyCommand
,DateCommand
,DeleteChatCommand
,DeleteGuildCommand
,DeputiesCommand
,DestroyCommand
,DetailsCommand
,DisarmCommand
,DownCommand
,DrinkCommand
,DropCommand
,EastCommand
,EatCommand
,EditChatCommand
,EmotionCommand
,EmotionToCommand
,EyebrowCommand
,GetCommand
,GiveCommand
,GoCommand
,GuildCommand
,GuildMasterCommand
,GuildMessageCommand
,HeehawCommand
,HelpCommand
,InventoryCommand
,ItemCommand
,JoinChatCommand
,LeaveChatCommand
,LeaveCommand
,LockCommand
,LookAtCommand
,LookCommand
,LookInCommand
,MacroCommand
,MeApostropheCommand
,MeCommand
,MessageCommand
,NormalCommand
,NorthCommand
,OocCommand
,OpenCommand
,OwnerCommand
,PostBoardCommand
,PutCommand
,RankAssignCommand
,RankChangeCommand
,RankDeleteCommand
,ReadBoardCommand
,ReadCommand
,RejectCommand
,RemoveCommand
,RetrieveCommand
,RibbitCommand
,SayCommand
,ScreamCommand
,ScriptCommand
,SellCommand
,ShoutCommand
,SingCommand
,SleepCommand
,SouthCommand
,StatsCommand
,TargetCommand
,TellCommand
,TimeCommand
,TitleCommand
,UndressCommand
,UnlockCommand
,UnwearCommand
,UnwieldCommand
,UpCommand
,WearCommand
,WestCommand
,WhisperCommand
,WieldCommand
,WimpyCommand
public interface Command
The interface used for all commands to be executed. Commands are executed by
characters. Bear in mind that commands are static classes devoid of state.
- Author:
- maartenl
-
Method Summary
Modifier and TypeMethodDescriptionreturns the regular expression the command structure must follow.Runs the command.
-
Method Details
-
run
Runs the command. The usual sequence of events is:- parsing the command string
- retrieving the appropriate information items/rooms/characters/etc)
- doing the action
- composing a return message for the user.
- Parameters:
command
- the String containing the full command.aUser
- the user that is executing the command- Returns:
- DisplayInterface to display to the user, if it returns null, it means the command was unsuccessfull.
- Throws:
MudException
- if something goes wrong.
-
getRegExpr
String getRegExpr()returns the regular expression the command structure must follow.- Returns:
- String containing the regular expression.
- See Also:
-