uk.ac.ed.inf.ogsaconfig.garm.collections.policies
Class PreservePolicy

java.lang.Object
  |
  +--uk.ac.ed.inf.ogsaconfig.garm.collections.policies.PreservePolicy
All Implemented Interfaces:
Policy

public class PreservePolicy
extends java.lang.Object
implements Policy

A policy that mandates no file ever be overwritten


Constructor Summary
PreservePolicy()
           
 
Method Summary
 boolean replace(VFile currentFile, VFile newFile)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PreservePolicy

public PreservePolicy()
Method Detail

replace

public boolean replace(VFile currentFile,
                       VFile newFile)
Specified by:
replace in interface Policy
Parameters:
currentFile - is the file currently in place
newFile - is the file that is a candidate to replace it
Returns:
true if the replacement should occur, false otherwise