|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mmbase.cache.Cache<TemplateCache.Key,Templates>
org.mmbase.cache.xslt.TemplateCache
public class TemplateCache
A cache for XSL transformation templates. A template can be based on a file, or on a string. In the first case the cache key is based on the file name, and the cache entry is invalidated if the file changes (so, if you uses 'imports' in the XSL template, you have to touch the file which imports, if the imported files changes). If the template is based on a string, then the string itself serves as a key.
| Nested Class Summary | |
|---|---|
static class |
TemplateCache.Key
Object to use as a key in the Caches. |
| Nested classes/interfaces inherited from interface java.util.Map |
|---|
Map.Entry<K,V> |
| Field Summary |
|---|
| Fields inherited from class org.mmbase.cache.Cache |
|---|
lock, maxEntrySize |
| Method Summary | |
|---|---|
void |
clear()
|
static TemplateCache |
getCache()
Returns the Template cache. |
String |
getDescription()
Gives a description for this cache type. |
String |
getName()
Returns a name for this cache type. |
Templates |
getTemplates(Source src)
|
Templates |
getTemplates(Source src,
URIResolver uri)
|
static void |
main(String[] argv)
Invocation of the class from the commandline for testing |
Templates |
put(Source src,
Templates value)
|
Templates |
put(Source src,
Templates value,
URIResolver uri)
|
Templates |
put(TemplateCache.Key key,
Templates value)
You can only put Source/Templates values in the cache, so this throws an Exception. |
Templates |
remove(Object o)
When removing an entry then also the FileWatcher must be removed. |
| Methods inherited from class org.mmbase.cache.Cache |
|---|
checkCachePolicy, contains, containsKey, containsValue, entrySet, equals, get, getAvarageValueLength, getByteSize, getByteSize, getCheapByteSize, getCount, getDefaultMaxEntrySize, getHits, getImplementation, getLock, getMaxEntrySize, getMaxSize, getMisses, getPuts, getRatio, getSize, getStats, hashCode, isActive, isEmpty, keySet, maxSize, putAll, putCache, reset, setActive, setMaxEntrySize, setMaxSize, size, toString, values |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Method Detail |
|---|
public static TemplateCache getCache()
public String getName()
Cache
getName in interface CacheMBeangetName in class Cache<TemplateCache.Key,Templates>public String getDescription()
Cache
getDescription in interface CacheMBeangetDescription in class Cache<TemplateCache.Key,Templates>public Templates getTemplates(Source src)
public Templates getTemplates(Source src,
URIResolver uri)
public Templates remove(Object o)
remove in interface Map<TemplateCache.Key,Templates>remove in class Cache<TemplateCache.Key,Templates>Map.remove(java.lang.Object)public void clear()
clear in interface Map<TemplateCache.Key,Templates>clear in interface CacheMBeanclear in class Cache<TemplateCache.Key,Templates>Map.clear()
public Templates put(TemplateCache.Key key,
Templates value)
put in interface Map<TemplateCache.Key,Templates>put in class Cache<TemplateCache.Key,Templates>RuntimeException
public Templates put(Source src,
Templates value)
public Templates put(Source src,
Templates value,
URIResolver uri)
public static void main(String[] argv)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||