public class SentimentAnalysisParser extends AbstractParser implements Initializable
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DEF_MODEL |
Constructor and Description |
---|
SentimentAnalysisParser() |
Modifier and Type | Method and Description |
---|---|
void |
checkInitialization(InitializableProblemHandler handler) |
java.util.Set<MediaType> |
getSupportedTypes(ParseContext context)
Returns the types supported
|
void |
initialize(java.util.Map<java.lang.String,Param> params) |
void |
parse(java.io.InputStream stream,
org.xml.sax.ContentHandler handler,
Metadata metadata,
ParseContext context)
Performs the parse
|
parse
public static final java.lang.String DEF_MODEL
public void initialize(java.util.Map<java.lang.String,Param> params) throws TikaConfigException
initialize
in interface Initializable
params
- params to use for initializationTikaConfigException
public void checkInitialization(InitializableProblemHandler handler) throws TikaConfigException
checkInitialization
in interface Initializable
handler
- if there is a problem and no
custom initializableProblemHandler has been configured
via Initializable parameters,
this is called to respond.TikaConfigException
public java.util.Set<MediaType> getSupportedTypes(ParseContext context)
getSupportedTypes
in interface Parser
context
- the parse contextpublic void parse(java.io.InputStream stream, org.xml.sax.ContentHandler handler, Metadata metadata, ParseContext context) throws java.io.IOException, org.xml.sax.SAXException, TikaException
parse
in interface Parser
stream
- the inputhandler
- the content handlermetadata
- the metadata passedcontext
- the context for the parserjava.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 parsed"Copyright © 2010 - 2020 Adobe Systems Incorporated. All Rights Reserved"