ePOST API

rice.p2p.replication
Interface ReplicationPolicy

All Known Implementing Classes:
ReplicationPolicy.DefaultReplicationPolicy

public interface ReplicationPolicy

Version:
$Id: ReplicationPolicy.java 2302 2005-03-11 00:58:26Z jeffh $
Author:
Alan Mislove

Nested Class Summary
static class ReplicationPolicy.DefaultReplicationPolicy
          The default policy for Replication, which simply does a direct diff between the sets
 
Method Summary
 IdSet difference(IdSet local, IdSet remote, IdFactory factory)
          This method is given a list of local ids and a list of remote ids, and should return the list of remote ids which need to be fetched.
 

Method Detail

difference

IdSet difference(IdSet local,
                 IdSet remote,
                 IdFactory factory)
This method is given a list of local ids and a list of remote ids, and should return the list of remote ids which need to be fetched. Thus, this method should return the set B-A, where the result is a subset of B.

Parameters:
local - The set of local ids
remote - The set of remote ids
factory - The factory to use to create IdSets
Returns:
A subset of the remote ids which need to be fetched

ePOST API

Copyright © 2001-2005 - Rice Pastry.