|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--dmc.TabbedChat
Manages chats with multiple targets in a single JTabbedPane. Also provides several functions for accessing information on the active connection.
Field Summary | |
protected dmc.AutoReader |
ar
|
protected dmc.ChatReader |
cr
|
protected dmc.MsgReader |
mr
|
protected dmc.SystemReader |
sr
|
protected javax.swing.JTabbedPane |
tabbedPane
|
protected wtalk.IUserList |
ul
|
protected dmc.WallReader |
wr
|
protected wtalk.WTalk |
wt
|
Constructor Summary | |
TabbedChat()
Default ctor. |
Method Summary | |
dmc.JChatPanel |
addTab(java.lang.String name,
int type)
Adds a new tab to the TabbedChat with caption name. |
void |
connect(java.lang.String server,
int port,
java.lang.String login)
Connects to server:port using login as a handle. |
dmc.ChatInputHandler |
getInputPanel(java.lang.String room)
Returns a ChatInputHandler associated with the JChatPanel in charge of room. |
javax.swing.JTabbedPane |
getUI()
Returns the GUI representation of a TabbedChat. |
java.lang.String |
getUserName()
Returns the user name as reported by the WTalkProtocol. |
javax.swing.JTextPane |
openBuddy(java.lang.String name)
Returns the JTextPane used by the JChatPanel displaying the chat with name. |
void |
setConnectionType(int i)
Sets the protocol used to connect. |
void |
setName(java.lang.String name)
Tells the WTalkProtocol to request a new name, name. |
void |
setPassword(java.lang.String passwd)
Tells the WTalkProtocol to use the given password when trying to authenticate. |
void |
setUserList(wtalk.IUserList u)
Sets the object to register with WTalkProtocols that will implement IUserList to support GUI representation of buddy lists. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected final javax.swing.JTabbedPane tabbedPane
protected final wtalk.WTalk wt
protected final dmc.ChatReader cr
protected final dmc.WallReader wr
protected final dmc.SystemReader sr
protected final dmc.MsgReader mr
protected final dmc.AutoReader ar
protected wtalk.IUserList ul
Constructor Detail |
public TabbedChat()
Method Detail |
public void setConnectionType(int i)
i
- Protocol to use, as defined in wtalk.Protocol.WTalk
,
Protocol
public void setUserList(wtalk.IUserList u)
u
- Object that will be used to manage user lists.public javax.swing.JTabbedPane getUI()
public dmc.ChatInputHandler getInputPanel(java.lang.String room)
room
- Room for which we want to get a ChatInputHandler.
public java.lang.String getUserName()
public void setName(java.lang.String name)
name
- Name to request.public void setPassword(java.lang.String passwd)
passwd
- Password to use to authenticate.public void connect(java.lang.String server, int port, java.lang.String login) throws java.io.IOException
server
- Host to connect to.port
- Port to connect to on host.login
- Name to login with.
java.io.IOException
- Throws IOException when the WTalkProtocol cannot
connect. For instance, the host is down, or cannot be resolved.public dmc.JChatPanel addTab(java.lang.String name, int type)
name
- Caption for tab.type
- Type of JChatPanel to create.
These are defined in JChatPanel.
JChatPanel
public javax.swing.JTextPane openBuddy(java.lang.String name)
name
- The handle of the user whose JChatPanel's JTextPane
is to be returned.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |