jxl.peermi
Class Multicast

java.lang.Object
  extended by jxl.peermi.Multicast

public final class Multicast
extends java.lang.Object

Helper class to perform multicast method invocations.

Note: This class could use a lot more testing. Fault tollerance, and null or void returns are still undefined.

Author:
Alex Lynch

Method Summary
static
<T> java.util.Collection<T>
multicast(PeerHashSet<? extends PeerRemote> peers, MethodCall<T> call)
          Make a multicast method invocation on the remote peers in peers.
static
<T> java.util.Collection<T>
multicast(PeerHashSet<? extends PeerRemote> peers, MethodCall<T> call, LimitedSearch<T> filter)
          Make a multicast method invocation on peers using filter to filter the results and to limmit the number of returns.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

multicast

public static <T> java.util.Collection<T> multicast(PeerHashSet<? extends PeerRemote> peers,
                                                    MethodCall<T> call)
Make a multicast method invocation on the remote peers in peers.

Parameters:
peers - The remote objects to call.
call - The method call to invoke
Returns:
A collection of objects returned from the invocations.

multicast

public static <T> java.util.Collection<T> multicast(PeerHashSet<? extends PeerRemote> peers,
                                                    MethodCall<T> call,
                                                    LimitedSearch<T> filter)
Make a multicast method invocation on peers using filter to filter the results and to limmit the number of returns.

Parameters:
peers - The remote objects to call.
call - The method call to invoke.
filter - the filter used to limit the number of returns and to filter the results.
Returns:
The collection of objects returned from the invocations that matched the filter.
See Also:
Search.matchesSearch(Object)