Rice Pastry API

org.mpisws.p2p.transport.rendezvous
Interface RendezvousStrategy<Identifier>

All Known Implementing Classes:
RendezvousApp

public interface RendezvousStrategy<Identifier>

Uses a 3rd party channel to request a node to connect to a dest.

Author:
Jeff Hoye

Field Summary
static int SUCCESS
           
 
Method Summary
 Cancellable openChannel(Identifier target, Identifier rendezvous, byte[] credentials, Continuation<java.lang.Integer,java.lang.Exception> deliverResultToMe)
          Calls ChannelOpener.openChannel(dest, credentials) on target Possible exceptions to deliverResultToMe: NodeIsFaultyException if target is faulty UnableToConnectException if dest is faulty
 MessageRequestHandle<Identifier,java.nio.ByteBuffer> sendMessage(Identifier i, java.nio.ByteBuffer m, MessageCallback<Identifier,java.nio.ByteBuffer> deliverAckToMe, java.util.Map<java.lang.String,java.lang.Object> options)
          Sends the message via an out-of-band channel.
 

Field Detail

SUCCESS

static final int SUCCESS
See Also:
Constant Field Values
Method Detail

openChannel

Cancellable openChannel(Identifier target,
                        Identifier rendezvous,
                        byte[] credentials,
                        Continuation<java.lang.Integer,java.lang.Exception> deliverResultToMe)
Calls ChannelOpener.openChannel(dest, credentials) on target Possible exceptions to deliverResultToMe: NodeIsFaultyException if target is faulty UnableToConnectException if dest is faulty

Parameters:
target - call ChannelOpener.openChannel() on this Identifier
rendezvous - pass this to ChannelOpener.openChannel(), it's who the ChannelOpener will connect to
credentials - this is also passed to ChannelOpener.openChannel()
deliverResultToMe - notify me when success/failure
Returns:
a way to cancel the request

sendMessage

MessageRequestHandle<Identifier,java.nio.ByteBuffer> sendMessage(Identifier i,
                                                                 java.nio.ByteBuffer m,
                                                                 MessageCallback<Identifier,java.nio.ByteBuffer> deliverAckToMe,
                                                                 java.util.Map<java.lang.String,java.lang.Object> options)
Sends the message via an out-of-band channel. Usually routing.

Parameters:
i -
m -
deliverAckToMe -
options -
Returns:

Rice Pastry API

Copyright © 2001-2005 - Rice Pastry.


Imprint-Dataprotection