public class TrackerRPC extends DispatchHandler
| Modifier and Type | Field and Description |
|---|---|
static int |
MAX_MSG_SIZE_UDP |
| Constructor and Description |
|---|
TrackerRPC(PeerBean peerBean,
ConnectionBean connectionBean) |
| Modifier and Type | Method and Description |
|---|---|
FutureResponse |
addToTracker(PeerAddress remotePeer,
AddTrackerBuilder builder,
ChannelCreator channelCreator) |
FutureResponse |
getFromTracker(PeerAddress remotePeer,
GetTrackerBuilder builder,
ChannelCreator channelCreator) |
void |
handleResponse(Message message,
PeerConnection peerConnection,
boolean sign,
Responder responder)
If the message is OK, that has been previously checked by the user using checkMessage, a reply to the message is
generated here.
|
static boolean |
isPrimary(FutureResponse response) |
static boolean |
isSecondary(FutureResponse response) |
connectionBean, createMessage, createResponseMessage, createResponseMessage, forwardMessage, peerBean, register, signpublic static final int MAX_MSG_SIZE_UDP
public TrackerRPC(PeerBean peerBean, ConnectionBean connectionBean)
peerBean - connectionBean - public static boolean isPrimary(FutureResponse response)
public static boolean isSecondary(FutureResponse response)
public FutureResponse addToTracker(PeerAddress remotePeer, AddTrackerBuilder builder, ChannelCreator channelCreator)
public FutureResponse getFromTracker(PeerAddress remotePeer, GetTrackerBuilder builder, ChannelCreator channelCreator)
public void handleResponse(Message message, PeerConnection peerConnection, boolean sign, Responder responder) throws Exception
DispatchHandlerhandleResponse in class DispatchHandlermessage - Request messagesign - Flag to indicate if message is signedException - Any exceptionCopyright © 2014. All rights reserved.