|
JXTA | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.jxta.impl.endpoint.router.RouteControl
public class RouteControl
Provides an "IOCTL" style interface to the JXTA router transport
Field Summary | |
---|---|
static int |
ALREADY_EXIST
|
static int |
DIRECT_ROUTE
|
static int |
FAILED
|
static int |
INVALID_ROUTE
|
static int |
OK
return value for operation |
Constructor Summary | |
---|---|
RouteControl(EndpointRouter router,
ID pid)
initialize RouteControl |
Method Summary | |
---|---|
boolean |
addMessengerFor(Object source,
EndpointAddress destination,
Messenger messenger)
Get the low level messenger for a destination. |
int |
addRoute(RouteAdvertisement newRoute)
add a new route. |
int |
deleteRoute(PeerID pId)
Delete route info |
void |
disableRouteCM()
disable usage of Route CM cache |
void |
disableRouteResolver()
disable usage of Route resolver |
void |
enableRouteCM()
enable usage of Route CM cache |
void |
enableRouteResolver()
enable usage of Route Resolver |
Vector<RouteAdvertisement> |
getAllRoutesInfo()
get all the know routes by the router. |
Messenger |
getMessengerFor(EndpointAddress destination,
Object hint)
Get the low level messenger for a destination. |
RouteAdvertisement |
getMyLocalRoute()
get my local route |
RouteAdvertisement |
getRouteInfo(PeerID pId)
Get a current route info |
boolean |
isConnected(PeerID pid)
Determines whether a connection to a specific node exists, or if one can be created. |
boolean |
useRouteCM()
get RouteCM usage |
boolean |
useRouteResolver()
get RouteResolver usage |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int OK
public static final int ALREADY_EXIST
public static final int FAILED
public static final int DIRECT_ROUTE
public static final int INVALID_ROUTE
Constructor Detail |
---|
public RouteControl(EndpointRouter router, ID pid)
router
- the routerpid
- the PeerIDMethod Detail |
---|
public RouteAdvertisement getMyLocalRoute()
public int addRoute(RouteAdvertisement newRoute)
newRoute
- route to add
public RouteAdvertisement getRouteInfo(PeerID pId)
pId
- destination of the route
public int deleteRoute(PeerID pId)
pId
- destination route to be removed
public Vector<RouteAdvertisement> getAllRoutesInfo()
public boolean useRouteCM()
public boolean useRouteResolver()
public void enableRouteCM()
public void disableRouteCM()
public void enableRouteResolver()
public void disableRouteResolver()
public boolean addMessengerFor(Object source, EndpointAddress destination, Messenger messenger)
source
- the source endpoint addressdestination
- the destination endpoint addressmessenger
- the messenger to add
public Messenger getMessengerFor(EndpointAddress destination, Object hint)
destination
- the destination endpoint addresshint
- route hint
public boolean isConnected(PeerID pid)
pid
- Node ID
|
JXSE | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |