lux.search.highlight
Class XmlHighlighter
java.lang.Object
lux.xml.SaxonDocBuilder
lux.search.highlight.XmlHighlighter
- All Implemented Interfaces:
- StAXHandler
public class XmlHighlighter
- extends SaxonDocBuilder
|
Method Summary |
void |
handleEvent(XMLStreamReader reader,
int eventType)
This method receives StAX events. |
net.sf.saxon.s9api.XdmNode |
highlight(org.apache.lucene.search.Query query,
net.sf.saxon.om.NodeInfo node)
|
void |
reset()
reinitialize any internal state and prepare the handler for re-use |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XmlHighlighter
public XmlHighlighter(net.sf.saxon.s9api.Processor processor,
IndexConfiguration indexConfig,
HighlightFormatter highlighter)
highlight
public net.sf.saxon.s9api.XdmNode highlight(org.apache.lucene.search.Query query,
net.sf.saxon.om.NodeInfo node)
throws XMLStreamException,
net.sf.saxon.s9api.SaxonApiException
- Throws:
XMLStreamException
net.sf.saxon.s9api.SaxonApiException
reset
public void reset()
- Description copied from interface:
StAXHandler
- reinitialize any internal state and prepare the handler for re-use
- Specified by:
reset in interface StAXHandler- Overrides:
reset in class SaxonDocBuilder
handleEvent
public void handleEvent(XMLStreamReader reader,
int eventType)
throws XMLStreamException
- Description copied from interface:
StAXHandler
- This method receives StAX events. It should never call XMLStreamReader.next()
since if it does, its caller will miss the event.
- Specified by:
handleEvent in interface StAXHandler- Overrides:
handleEvent in class SaxonDocBuilder
- Parameters:
reader - the reader from which events are being readeventType - the XML stream event type
- Throws:
XMLStreamException
Copyright © 2013. All Rights Reserved.