*/
public boolean replace(Element old, Element element, ElementValueComparator comparator)
throws NullPointerException, IllegalArgumentException {
Sync lock = sync.getSyncForKey(old.getObjectKey());
lock.lock(LockType.WRITE);
try {
Element current = getQuiet(old.getObjectKey());
if (comparator.equals(old, current)) {
put(element);
return true;