com.threerings.crowd.chat.client
Class ChatDirector.BroadcastHandler

java.lang.Object
  extended by com.threerings.crowd.chat.client.ChatDirector.CommandHandler
      extended by com.threerings.crowd.chat.client.ChatDirector.BroadcastHandler
Enclosing class:
ChatDirector

protected class ChatDirector.BroadcastHandler
extends ChatDirector.CommandHandler

Implements /broadcast.


Field Summary
 
Fields inherited from class com.threerings.crowd.chat.client.ChatDirector.CommandHandler
_aliases, _usageKey
 
Constructor Summary
protected ChatDirector.BroadcastHandler()
           
 
Method Summary
 boolean checkAccess(BodyObject user)
          Returns true if this user should have access to this chat command.
 String handleCommand(SpeakService speakSvc, String command, String args, String[] history)
          Handles the specified chat command.
 
Methods inherited from class com.threerings.crowd.chat.client.ChatDirector.CommandHandler
getUsage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ChatDirector.BroadcastHandler

protected ChatDirector.BroadcastHandler()
Method Detail

handleCommand

public String handleCommand(SpeakService speakSvc,
                            String command,
                            String args,
                            String[] history)
Description copied from class: ChatDirector.CommandHandler
Handles the specified chat command.

Specified by:
handleCommand in class ChatDirector.CommandHandler
Parameters:
speakSvc - an optional SpeakService object representing the object to send the chat message on.
command - the slash command that was used to invoke this handler (e.g. /tell).
args - the arguments provided along with the command (e.g. Bob hello) or null if no arguments were supplied.
history - an in/out parameter that allows the command to modify the text that will be appended to the chat history. If this is set to null, nothing will be appended.
Returns:
an untranslated string that will be reported to the chat box to convey an error response to the user, or ChatCodes.SUCCESS.

checkAccess

public boolean checkAccess(BodyObject user)
Description copied from class: ChatDirector.CommandHandler
Returns true if this user should have access to this chat command.

Overrides:
checkAccess in class ChatDirector.CommandHandler