ggz.ui
Class ChatAction

java.lang.Object
  extended by javax.swing.AbstractAction
      extended by ggz.ui.ChatAction
All Implemented Interfaces:
java.awt.event.ActionListener, java.io.Serializable, java.lang.Cloneable, java.util.EventListener, javax.swing.Action
Direct Known Subclasses:
GamePanel.TableChatAction, PrivateChatDialog.PrivateChatAction, RoomChatPanel.RoomChatAction

public abstract class ChatAction
extends javax.swing.AbstractAction

See Also:
Serialized Form

Field Summary
protected  ChatPanel chatPanel
           
 
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
 
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
 
Constructor Summary
ChatAction()
           
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
           
protected abstract  void chat_display_local(ChatType type, java.lang.String message)
           
protected abstract  ChatType getDefaultChatType()
           
protected abstract  boolean sendAdmin(AdminType type, java.lang.String target, java.lang.String reason)
           
 void sendBeep(java.lang.String target)
           
protected abstract  boolean sendChat(ChatType chatType, java.lang.String target, java.lang.String message)
          Performs the requested chat operation.
 
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

chatPanel

protected ChatPanel chatPanel
Constructor Detail

ChatAction

public ChatAction()
Method Detail

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)

chat_display_local

protected abstract void chat_display_local(ChatType type,
                                           java.lang.String message)

sendBeep

public void sendBeep(java.lang.String target)
              throws java.io.IOException
Throws:
java.io.IOException

sendChat

protected abstract boolean sendChat(ChatType chatType,
                                    java.lang.String target,
                                    java.lang.String message)
                             throws java.io.IOException
Performs the requested chat operation. If a particular chat operation is not allowed this method should return false.

Parameters:
chatType -
target -
message -
Returns:
true if the operation was performed, false otherwise.
Throws:
java.io.IOException

getDefaultChatType

protected abstract ChatType getDefaultChatType()

sendAdmin

protected abstract boolean sendAdmin(AdminType type,
                                     java.lang.String target,
                                     java.lang.String reason)
                              throws java.io.IOException
Throws:
java.io.IOException