|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.relayirc.chatengine.Channel
An IRC channel class that includes methods for joining, parting, kicking, banning, adding/removing channel listeners and property change support.
The contents of this file are subject to the Mozilla Public License Version 1.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.mozilla.org/MPL/
Original Code: Relay IRC Chat EngineConstructor Summary | |
Channel(java.lang.String name)
Construct channel with name alone. |
|
Channel(java.lang.String name,
Server server)
Construct channel with server. |
|
Channel(java.lang.String name,
java.lang.String topic,
int ucount,
Server server)
Channel with name, topic, user count and a server. |
Method Summary | |
void |
activate()
Request that this channel be activated, given-focus or brought-to-front. |
void |
addChannelListener(ChannelListener listener)
Channel listener support. |
void |
addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Property change support. |
void |
connect()
Connect/join this channel, does nothing if channel has no server. |
void |
disconnect()
Request channel disconnection by sending PART command to server. |
boolean |
equals(java.lang.Object object)
|
java.lang.String |
getDescription()
Get object's description. |
int |
getMaxNumBufferedUnsentMessages()
|
java.lang.String |
getName()
Get name of channel (e.g. |
Server |
getServer()
Get the channel's server, which may be null. |
java.lang.String |
getTopic()
Get channe's topic. |
int |
getUserCount()
Number of users currently on channel. |
boolean |
isConnected()
True if channel is connected/joined. |
void |
removeChannelListener(ChannelListener listener)
Channel listener support. |
void |
removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Property change support. |
void |
sendAction(java.lang.String msg)
Send an action to this channel. |
void |
sendBan(java.lang.String nick)
Ban a user from this channel. |
void |
sendDeop(java.lang.String nick)
Take operator rights from a user. |
void |
sendJoin()
Join this channel, requires a server. |
void |
sendKick(java.lang.String nick)
Kick a user from the channel. |
void |
sendMessage(java.lang.String message)
Send a one line or multiline message to this channel. |
void |
sendNotice(java.lang.String msg)
Send a NOTICE to this channel. |
void |
sendOp(java.lang.String nick)
Give operator rights to a user. |
void |
sendPart()
Part (leave) this channel. |
void |
sendPrivMsg(java.lang.String str)
Send PRIVMSG to this channel. |
void |
setDescription(java.lang.String desc)
Set object's description. |
void |
setMaxNumBufferedUnsentMessages(int newMaxNumBufferedUnsentMessages)
Insert the method's description here. |
void |
setName(java.lang.String name)
Set channel name, with property change support. |
void |
setServer(Server server)
Set the server to be used by this channel. |
void |
setTopic(java.lang.String topic)
Set channel topic, with property change support. |
void |
setUserCount(int count)
Set channel user count, with property change support. |
java.lang.String |
toString()
String representation is channel name. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Channel(java.lang.String name)
public Channel(java.lang.String name, Server server)
public Channel(java.lang.String name, java.lang.String topic, int ucount, Server server)
Method Detail |
public boolean equals(java.lang.Object object)
equals
in class java.lang.Object
public void addChannelListener(ChannelListener listener)
public void removeChannelListener(ChannelListener listener)
public void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
public void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
public boolean isConnected()
public Server getServer()
public int getMaxNumBufferedUnsentMessages()
public void connect()
public void disconnect()
public java.lang.String getName()
public void setServer(Server server)
public void setName(java.lang.String name)
public java.lang.String getTopic()
public java.lang.String getDescription()
IChatObject
getDescription
in interface IChatObject
public void setDescription(java.lang.String desc)
IChatObject
setDescription
in interface IChatObject
public void setTopic(java.lang.String topic)
public int getUserCount()
public void setUserCount(int count)
public java.lang.String toString()
toString
in class java.lang.Object
public void activate()
public void sendNotice(java.lang.String msg)
public void sendAction(java.lang.String msg)
public void sendBan(java.lang.String nick)
public void sendDeop(java.lang.String nick)
public void sendJoin()
public void sendKick(java.lang.String nick)
public void sendMessage(java.lang.String message)
public void sendOp(java.lang.String nick)
public void sendPart()
public void sendPrivMsg(java.lang.String str)
public void setMaxNumBufferedUnsentMessages(int newMaxNumBufferedUnsentMessages)
newMaxNumBufferedUnsentMessages
- i
int 0 is don't buffer, -1 is umlimited size, n is number of lines
buffered
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |