org.jcreme.caches
Interface ModifiableCache

All Superinterfaces:
Cache
All Known Implementing Classes:
AggregateCache

public interface ModifiableCache
extends Cache

This extension of the Cache interface signals the caches that allow a change in the CachePolicy.

Version:
$Revision: 1.2 $
Author:
$Author: dbregeon $

Method Summary
 void setReplacementPolicy(CachePolicy policy)
          This method changes both the storage policy and the inner cache.
 
Methods inherited from interface org.jcreme.caches.Cache
addCacheListener, clear, getAllObjects, getAllObjects, getCacheListeners, getMap, getMaxSize, getObject, getReplacementPolicy, getSize, registerAllObjects, registerObject, removeCacheListener, setMaxSize, unregisterObject
 

Method Detail

setReplacementPolicy

public void setReplacementPolicy(CachePolicy policy)
                          throws java.lang.IllegalArgumentException
This method changes both the storage policy and the inner cache. All the objects contained in the cache remain under the new policy.

Parameters:
policy - the policy to use to store objects.
Throws:
java.lang.IllegalArgumentException - when the policy is null.


Copyright 2006 null. All Rights Reserved.