rice.p2p.past
Class PastPolicy.DefaultPastPolicy
java.lang.Object
  
rice.p2p.past.PastPolicy.DefaultPastPolicy
- 
All Implemented Interfaces: 
 
- PastPolicy
 
- Enclosing interface:
 
- PastPolicy
 
- 
public static class PastPolicy.DefaultPastPolicy
- extends java.lang.Object
- implements PastPolicy
 
 
 
The default policy for Past, which fetches any available copy of a replicated object and
 always allows inserts locally.
- Author:
 
  - Alan Mislove
 
 
 
 
 
| Methods inherited from class java.lang.Object | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
PastPolicy.DefaultPastPolicy
public PastPolicy.DefaultPastPolicy()
fetch
public void fetch(Id id,
                  NodeHandle hint,
                  Cache backup,
                  Past past,
                  Continuation command)
- This method fetches the object via a lookup() call.
- 
- Specified by:
 
- 
fetch in interface PastPolicy
 
 
- 
- Parameters:
 
- 
id - The id to fetch- 
hint - A hint as to where the key might be- 
backup - The backup cache, where the object *might* be located- 
past - The local past instance- 
command - The command to call with the replica to store 
 
 
 
 
 
 
allowInsert
public boolean allowInsert(PastContent content)
- This method always return true;
- 
- Specified by:
 
- 
allowInsert in interface PastPolicy
 
 
- 
- Parameters:
 
- 
content - The content about to be stored
 
- Returns:
 
- Whether the insert should be allowed
 
 
 
Copyright © 2001-2005 - Rice Pastry.