|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.tomp2p.connection.ChannelCreator
public class ChannelCreator
Creates the channels. This class is created by ConnectionReservation
and should never be called directly.
Method Summary | |
---|---|
org.jboss.netty.channel.ChannelFuture |
close(PeerAddress destination)
Closes a permanent connection. |
org.jboss.netty.channel.ChannelFuture |
createTCPChannel(ReplyTimeoutHandler timeoutHandler,
RequestHandlerTCP<? extends BaseFuture> requestHandler,
FutureResponse futureResponse,
int connectTimeoutMillis,
InetSocketAddress recipient)
Creates a TCP channel future. |
org.jboss.netty.channel.Channel |
createUDPChannel(ReplyTimeoutHandler timeoutHandler,
RequestHandlerUDP<? extends BaseFuture> requestHandler,
FutureResponse futureResponse,
boolean broadcast)
Creates a UDP channel. |
long |
getCreatorThread()
|
String |
getName()
|
int |
getPermits()
|
boolean |
hasNoPermits()
|
void |
shutdown()
Shuts down this channelcreator. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public org.jboss.netty.channel.Channel createUDPChannel(ReplyTimeoutHandler timeoutHandler, RequestHandlerUDP<? extends BaseFuture> requestHandler, FutureResponse futureResponse, boolean broadcast)
timeoutHandler
- The handler that deals with timeoutsrequestHandler
- The handler that deals with incoming repliesfutureResponse
- The future object that takes care of future eventsbroadcast
- Set to true if broadcast is allowed
public org.jboss.netty.channel.ChannelFuture createTCPChannel(ReplyTimeoutHandler timeoutHandler, RequestHandlerTCP<? extends BaseFuture> requestHandler, FutureResponse futureResponse, int connectTimeoutMillis, InetSocketAddress recipient)
timeoutHandler
- The handler that deals with timeoutsrequestHandler
- The handler that deals with incoming repliesfutureResponse
- The future object that takes care of future eventsconnectTimeoutMillis
- The timeout after which a connection attempt
is considered a failurerecipient
- The recipient to create the connection. If the recipient
is already open, the connection will be reused.
public org.jboss.netty.channel.ChannelFuture close(PeerAddress destination)
destination
- The address of the destination peer of the permanent
connection.
public int getPermits()
public boolean hasNoPermits()
public void shutdown()
public String getName()
public long getCreatorThread()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |