freemarker.template
Interface BinaryCache

All Known Implementing Classes:
FileBinaryCache

public interface BinaryCache

An interface for self-updating caches of compiled BinaryDatas.

See Also:
FileBinaryCache

Method Summary
 void addCacheListener(CacheListener listener)
          Registers a CacheListener for this BinaryCache.
 BinaryData getBinaryData(java.lang.String name)
          Gets a BinaryData object from the cache.
 java.util.Iterator listCachedFiles()
          Returns an iterator over a list of CacheElement instances
 void removeCacheListener(CacheListener listener)
          Unregisters a CacheListener for this BinaryCache.
 void startAutoUpdate()
          Deprecated.  
 void stopAutoUpdate()
          Deprecated.  
 

Method Detail

addCacheListener

public void addCacheListener(CacheListener listener)
Registers a CacheListener for this BinaryCache.
Parameters:
CacheListener - the CacheListener to be registered.
See Also:
CacheListener

removeCacheListener

public void removeCacheListener(CacheListener listener)
Unregisters a CacheListener for this BinaryCache.
Parameters:
CacheListener - the CacheListener to be unregistered.
See Also:
CacheListener

getBinaryData

public BinaryData getBinaryData(java.lang.String name)
Gets a BinaryData object from the cache.
Parameters:
name - a string uniquely identifying the binary data object.
Returns:
the binary data object corresponding to the name, or null if not found.

startAutoUpdate

public void startAutoUpdate()
Deprecated.  

Note: startAutoUpdate() is deprecated. An implementation will automatically call startAutoUpdate() or its equivalent internally as determined by the caching policy

Begins automatic updates of the cache.


stopAutoUpdate

public void stopAutoUpdate()
Deprecated.  

Note: startAutoUpdate() is deprecated. An implementation will automatically call startAutoUpdate() or its equivalent internally as determined by the caching policy

Stops automatically updating the cache.


listCachedFiles

public java.util.Iterator listCachedFiles()
Returns an iterator over a list of CacheElement instances
Returns:
the iterator over a list of CacheElement instances that correspond to templates in the cache