|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
com.jivesoftware.spark.component.BackgroundPanel
com.jivesoftware.spark.ui.ChatRoom
com.jivesoftware.spark.ui.rooms.ChatRoomImpl
This is the Agent to Agent implementation of ChatRoom
This room only allows for 1 to 1 conversations.
| Nested Class Summary |
| Nested classes inherited from class com.jivesoftware.spark.ui.ChatRoom |
ChatRoom.ChatToolBar |
| Nested classes inherited from class javax.swing.JPanel |
javax.swing.JPanel.AccessibleJPanel |
| Nested classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
| Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
| Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
| Field Summary |
| Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
ChatRoomImpl(java.lang.String participantJID,
java.lang.String participantNickname,
java.lang.String title)
Constructs a 1-to-1 ChatRoom. |
|
| Method Summary | |
void |
addMessageEventListener(MessageEventListener listener)
|
void |
closeChatRoom()
Close the ChatRoom. |
void |
fireOutgoingMessageSending(org.jivesoftware.smack.packet.Message message)
|
void |
fireReceivingIncomingMessage(org.jivesoftware.smack.packet.Message message)
|
org.jivesoftware.smack.packet.Message.Type |
getChatType()
Returns the Message.Type specific to this
chat room. |
java.lang.String |
getJID()
Returns the users full jid (ex. |
java.util.Collection |
getMessageEventListeners()
|
java.lang.String |
getParticipantJID()
|
java.lang.String |
getParticipantNickname()
Returns the nickname of the user chatting with. |
java.lang.String |
getRoomname()
Get the roomname to use for this ChatRoom. |
java.lang.String |
getRoomTitle()
Returns the title of this room to use. |
javax.swing.Icon |
getTabIcon()
Get the Icon to be used in the tab holding
this ChatRoom. |
java.lang.String |
getTabTitle()
Get the title to use in the tab holding this ChatRoom. |
void |
insertMessage(org.jivesoftware.smack.packet.Message message)
The main entry point when receiving any messages. |
void |
insertUpdate(javax.swing.event.DocumentEvent e)
The current SendField has been updated somehow. |
boolean |
isActive()
Returns whether or not this ChatRoom is active. |
void |
leaveChatRoom()
Disable the chat room. |
void |
processPacket(org.jivesoftware.smack.packet.Packet packet)
Process incoming packets. |
void |
removeMessageEventListener(MessageEventListener listener)
|
void |
sendMessage()
Creates and sends a message object from the text in the Send Field, using the default nickname specified in your Chat Preferences. |
void |
sendMessage(org.jivesoftware.smack.packet.Message message)
Sends a message to the appropriate jid. |
void |
sendMessage(java.lang.String text)
Creates a Message object from the given text and delegates to the room for sending. |
| Methods inherited from class com.jivesoftware.spark.component.BackgroundPanel |
paintComponent, setBackgroundImage |
| Methods inherited from class javax.swing.JPanel |
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class javax.swing.JComponent |
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
| Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, addImpl, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree |
| Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public ChatRoomImpl(java.lang.String participantJID,
java.lang.String participantNickname,
java.lang.String title)
participantJID - the participants jid to chat with.participantNickname - the nickname of the participant.title - the title of the room.| Method Detail |
public void closeChatRoom()
ChatRoom
closeChatRoom in class ChatRoompublic void sendMessage()
ChatRoom
sendMessage in class ChatRoompublic void sendMessage(java.lang.String text)
ChatRoom
sendMessage in class ChatRoomtext - the text to send.public void sendMessage(org.jivesoftware.smack.packet.Message message)
sendMessage in class ChatRoommessage - the message to send.public java.lang.String getRoomname()
ChatRoom
getRoomname in class ChatRoompublic javax.swing.Icon getTabIcon()
ChatRoomIcon to be used in the tab holding
this ChatRoom.
getTabIcon in class ChatRoomIcon to usepublic java.lang.String getTabTitle()
ChatRoom
getTabTitle in class ChatRoompublic java.lang.String getRoomTitle()
ChatRoom
getRoomTitle in class ChatRoompublic org.jivesoftware.smack.packet.Message.Type getChatType()
ChatRoomMessage.Type specific to this
chat room.
GroupChat is Message.Type.GROUP_CHAT
Normal Chat is Message.TYPE.NORMAL
getChatType in class ChatRoompublic void leaveChatRoom()
ChatRoom
leaveChatRoom in class ChatRoompublic boolean isActive()
ChatRoom
isActive in class ChatRoompublic java.lang.String getParticipantJID()
public java.lang.String getJID()
public void processPacket(org.jivesoftware.smack.packet.Packet packet)
processPacket in interface org.jivesoftware.smack.PacketListenerprocessPacket in class ChatRoompacket - - the packet to processpublic java.lang.String getParticipantNickname()
public void insertUpdate(javax.swing.event.DocumentEvent e)
insertUpdate in interface javax.swing.event.DocumentListenerinsertUpdate in class ChatRoome - - the DocumentEvent to respond to.public void insertMessage(org.jivesoftware.smack.packet.Message message)
ChatRoom
insertMessage in class ChatRoommessage - - the message receieved.public void addMessageEventListener(MessageEventListener listener)
public void removeMessageEventListener(MessageEventListener listener)
public java.util.Collection getMessageEventListeners()
public void fireOutgoingMessageSending(org.jivesoftware.smack.packet.Message message)
public void fireReceivingIncomingMessage(org.jivesoftware.smack.packet.Message message)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||