public class DigestingParser extends ParserDecorator
Modifier and Type | Class and Description |
---|---|
static interface |
DigestingParser.Digester
Interface for digester.
|
static interface |
DigestingParser.Encoder
Encodes byte array from a MessageDigest to String
|
Constructor and Description |
---|
DigestingParser(Parser parser,
DigestingParser.Digester digester)
Creates a decorator for the given parser.
|
Modifier and Type | Method and Description |
---|---|
void |
parse(java.io.InputStream stream,
org.xml.sax.ContentHandler handler,
Metadata metadata,
ParseContext context)
Delegates the method call to the decorated parser.
|
getDecorationName, getSupportedTypes, getWrappedParser, withFallbacks, withoutTypes, withTypes
parse
public DigestingParser(Parser parser, DigestingParser.Digester digester)
parser
- the parser instance to be decoratedpublic void parse(java.io.InputStream stream, org.xml.sax.ContentHandler handler, Metadata metadata, ParseContext context) throws java.io.IOException, org.xml.sax.SAXException, TikaException
ParserDecorator
super.parse()
to invoke
the decorated parser) to implement extra decoration.parse
in interface Parser
parse
in class ParserDecorator
stream
- the document stream (input)handler
- handler for the XHTML SAX events (output)metadata
- document metadata (input and output)context
- parse contextjava.io.IOException
- if the document stream could not be readorg.xml.sax.SAXException
- if the SAX events could not be processedTikaException
- if the document could not be parsedCopyright © 2010 - 2020 Adobe. All Rights Reserved