|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface VirtualChannel
Virtualized Channel that allows different implementations.
| Method Summary | ||
|---|---|---|
|
call(Callable<V,T> callable)
Makes a remote procedure call. |
|
|
callAsync(Callable<V,T> callable)
Makes an asynchronous remote procedure call. |
|
void |
close()
Performs an orderly shut down of this channel (and the remote peer.) |
|
|
export(java.lang.Class<T> type,
T instance)
Exports an object for remoting to the other Channel
by creating a remotable proxy. |
|
void |
join()
Waits for this Channel to be closed down. |
|
void |
join(long timeout)
Waits for this Channel to be closed down, but only up the given milliseconds. |
|
void |
syncLocalIO()
Blocks until all the I/O packets sent from remote is fully locally executed, then return. |
|
| Method Detail |
|---|
<V,T extends java.lang.Throwable> V call(Callable<V,T> callable)
throws java.io.IOException,
T extends java.lang.Throwable,
java.lang.InterruptedException
Sends Callable to the remote system, executes it, and returns its result.
java.lang.InterruptedException - If the current thread is interrupted while waiting for the completion.
java.io.IOException - If there's any error in the communication between Channels.
T extends java.lang.Throwable
<V,T extends java.lang.Throwable> Future<V> callAsync(Callable<V,T> callable)
throws java.io.IOException
Similar to call(Callable) but returns immediately.
The result of the Callable can be obtained through the Future object.
Future object that can be used to wait for the completion.
java.io.IOException - If there's an error during the communication.
void close()
throws java.io.IOException
java.io.IOException - if the orderly shut-down failed.
void join()
throws java.lang.InterruptedException
Channel to be closed down.
The close-down of a Channel might be initiated locally or remotely.
java.lang.InterruptedException - If the current thread is interrupted while waiting for the completion.
void join(long timeout)
throws java.lang.InterruptedException
Channel to be closed down, but only up the given milliseconds.
java.lang.InterruptedException - If the current thread is interrupted while waiting for the completion.
<T> T export(java.lang.Class<T> type,
T instance)
Channel
by creating a remotable proxy.
All the parameters and return values must be serializable.
type - Interface to be remoted.
Channel, and calling methods on it from the remote side
will invoke the same method on the given local instance object.
void syncLocalIO()
throws java.lang.InterruptedException
java.lang.InterruptedException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||