protected void clear(ReadWriteLock lock) {

    Lock writeLock = lock.writeLock();

    try {
      writeLock.lock();
      getCache().clear();
    }
    finally {
      writeLock.unlock();
    }
  }
protected void clear ( ReadWriteLock lock ) { Lock writeLock = lock . writeLock ( ) ; try { writeLock . lock ( ) ; getCache ( ) . clear ( ) ; } finally { writeLock . unlock ( ) ; } }
Clears the entire contents of the {@link Cache}.

The {@link Cache} operation acquires a write lock.

@param lock {@link ReadWriteLock} used to coordinate the {@link Cache} clear operation
with possibly other concurrent {@link Cache} operations.
@see java.util.concurrent.locks.ReadWriteLock#writeLock()
@see #getCache()