|
Xindice API version 1.1 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.xindice.core.DocumentCache
DocumentCache implements a simple Document caching system for Collections. FIXME: Revisit cache implementation. Most probably, commons collections' ReferenceMap should be used instead of WeakHashMap.
Constructor Summary | |
DocumentCache()
|
Method Summary | |
static int |
getCacheControl(org.w3c.dom.Document doc)
Obtains value of the cache control processing instruction in this document |
org.w3c.dom.Document |
getDocument(Collection col,
Key key)
Obtains document from cache |
void |
putDocument(Collection col,
Key key,
byte[] bytes)
Stores compressed document's bytes in the cache |
void |
putDocument(Collection col,
Key key,
String chars)
Stores serialized document's text in the cache |
void |
removeDocument(Collection col,
Key key)
Remove document from the cache |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public DocumentCache()
Method Detail |
public org.w3c.dom.Document getDocument(Collection col, Key key)
col
- document collectionkey
- document keypublic void putDocument(Collection col, Key key, byte[] bytes)
col
- document collectionkey
- document keybytes
- compressed documentpublic void putDocument(Collection col, Key key, String chars)
col
- document collectionkey
- document keychars
- uncompressed documentpublic void removeDocument(Collection col, Key key)
col
- document collectionkey
- document keypublic static int getCacheControl(org.w3c.dom.Document doc)
doc
- document to inspect for cache control processing instruction
|
Xindice API version 1.1 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |