|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectnet.jackofalltrades.irc.BaseConnection
net.jackofalltrades.irc.dcc.BaseDccConnection
Provides event handler functionality for DCC connections, and provides
facilites to write output to the underlying Socket.
| Field Summary |
| Fields inherited from class net.jackofalltrades.irc.BaseConnection |
DEFAULT_BUFFER_SIZE, DEFAULT_CONNECTION_TIMEOUT, DEFAULT_READ_WRITE_TIMEOUT, MAX_PORT, MIN_PORT |
| Constructor Summary | |
BaseDccConnection()
Creates a new BaseDccConnection. |
|
BaseDccConnection(java.net.InetAddress remoteHost,
int port)
Creates a new BaseDccConnection to connect to the specified
remote host. |
|
BaseDccConnection(java.net.Socket socket)
Creates a new BaseDccConnection connected on the specified
java.net.Socket. |
|
BaseDccConnection(java.lang.String remoteHost,
int port)
Creates a new BaseDccConnection to connect to the specified
remote host. |
|
| Method Summary | |
void |
addDccDataListener(IrcCommandListener l)
Registers an IrcCommandListener for all commands. |
void |
dataPrepared(DccDataEvent event)
Writes data to the output stream. |
void |
dataReceived(DccDataEvent event)
Does nothing. |
protected void |
fireDataReceived(DccDataEvent event)
|
void |
removeDccDataListener(IrcCommandListener l)
Removes an IrcCommandListener from the list of registered
listeners for all commands. |
protected void |
wrapOutput(java.io.OutputStream output)
Wraps the OutputStream in a java.io.Writer. |
| Methods inherited from class net.jackofalltrades.irc.BaseConnection |
addConnectionListener, addEventListener, connect, disconnect, getBufferSize, getConnectionTimeout, getEventListeners, getLastException, getPortNumber, getReadWriteTimeout, getRemoteHost, isConnected, processInput, removeConnectionListener, removeEventListener, run, setBufferSize, setConnectionTimeout, setLastException, setPortNumber, setReadWriteTimeout, setRemoteHost, wrapInput |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public BaseDccConnection()
BaseDccConnection.
public BaseDccConnection(java.net.InetAddress remoteHost,
int port)
BaseDccConnection to connect to the specified
remote host.
remoteHost - the java.net.InetAddress of the remote
host.port - the port number on the remote host.
java.lang.IllegalArgumentException - if remoteHost is
null or if port is not in the range 1 - 65535.
public BaseDccConnection(java.lang.String remoteHost,
int port)
throws java.net.UnknownHostException
BaseDccConnection to connect to the specified
remote host.
remoteHost - the name of the remote host.port - the port number on the server.
java.net.UnknownHostException - if the remoteHost
cannot be resolved.
java.lang.IllegalArgumentException - if the remoteHostpublic BaseDccConnection(java.net.Socket socket)
BaseDccConnection connected on the specified
java.net.Socket.
socket - the Socket connected to the remote host.| Method Detail |
public void dataPrepared(DccDataEvent event)
dataPrepared in interface DccDataListenerevent - the event fired by a DCC data generating component.protected void wrapOutput(java.io.OutputStream output)
OutputStream in a java.io.Writer.
wrapOutput in class BaseConnectionoutput - the OutputStream from the underlying
java.net.Socket.public void dataReceived(DccDataEvent event)
dataReceived in interface DccDataListenerprotected void fireDataReceived(DccDataEvent event)
public void addDccDataListener(IrcCommandListener l)
IrcCommandListener for all commands.
l - the new registered listener.public void removeDccDataListener(IrcCommandListener l)
IrcCommandListener from the list of registered
listeners for all commands.
l - the listener to remove.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||