|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Receives callback event during document(s) loading and removal; implemented by several classes that generate various indices; Observer Design Pattern: role Observer; the class @link org.exist.storage.NativeBroker is the subject (alias observable). startElement() and endElement() bear the same names as the corresponding SAX events. However storeXXX() have no corresponding method in SAX. Note: when we will have more than one runtime switch , we will refactor fullTextIndexSwitch into an object
Method Summary | |
void |
dropIndex(Collection collection)
Drop all index entries for the given collection. |
void |
dropIndex(DocumentImpl doc)
Drop all index entries for the given document. |
void |
endElement(int xpathType,
ElementImpl node,
java.lang.String content)
store and index given element (called storeElement before) |
void |
flush()
writes the pending items, for the current document's collection |
void |
reindex(DocumentImpl oldDoc,
StoredNode node)
Reindexes all pending items for the specified document. |
void |
remove()
remove all pending modifications, for the current document. |
void |
removeElement(ElementImpl node,
NodePath currentPath,
java.lang.String content)
Mark given Element for removal; added entries are written to the list of pending entries. |
void |
setDocument(DocumentImpl document)
set the current document; generally called before calling an operation |
void |
startElement(ElementImpl impl,
NodePath currentPath,
boolean index)
corresponds to SAX function of the same name |
void |
storeAttribute(AttrImpl node,
NodePath currentPath,
boolean fullTextIndexSwitch)
store and index given attribute |
void |
storeText(TextImpl node,
NodePath currentPath,
boolean fullTextIndexSwitch)
store and index given text node |
void |
sync()
triggers a cache sync, i.e. |
Method Detail |
public void storeAttribute(AttrImpl node, NodePath currentPath, boolean fullTextIndexSwitch)
public void storeText(TextImpl node, NodePath currentPath, boolean fullTextIndexSwitch)
public void startElement(ElementImpl impl, NodePath currentPath, boolean index)
public void endElement(int xpathType, ElementImpl node, java.lang.String content)
public void removeElement(ElementImpl node, NodePath currentPath, java.lang.String content)
flush()
is called later to flush all pending entries.
public void setDocument(DocumentImpl document)
public void flush()
public void sync()
public void dropIndex(Collection collection)
collection
- public void dropIndex(DocumentImpl doc) throws ReadOnlyException
doc
-
ReadOnlyException
public void reindex(DocumentImpl oldDoc, StoredNode node)
oldDoc
- the document to be reindexed.node
- if != null, only nodes being descendants of the specified node will be
reindexed. Other nodes are not touched. This is used for a partial reindex.public void remove()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |