public class SocketForwardingConnectListener extends java.lang.Object implements ConnectListener
ConnectListener that forwards what is received over the channel to a socket and vice-versa.| Modifier and Type | Field and Description |
|---|---|
protected java.net.SocketAddress |
addr |
protected org.slf4j.Logger |
log |
| Constructor and Description |
|---|
SocketForwardingConnectListener(java.net.SocketAddress addr)
Create with a
SocketAddress this listener will forward to. |
| Modifier and Type | Method and Description |
|---|---|
void |
gotConnect(Channel.Forwarded chan)
On connect, confirm the channel and start forwarding.
|
protected final org.slf4j.Logger log
protected final java.net.SocketAddress addr
public SocketForwardingConnectListener(java.net.SocketAddress addr)
SocketAddress this listener will forward to.public void gotConnect(Channel.Forwarded chan) throws java.io.IOException
gotConnect in interface ConnectListenerchan - the forwarded channeljava.io.IOException - if there is a problem handling the channel