public class TensorflowRESTCaptioner extends java.lang.Object implements ObjectRecogniser
NOTE : https://wiki.apache.org/tika/ImageCaption
| Constructor and Description |
|---|
TensorflowRESTCaptioner() |
| Modifier and Type | Method and Description |
|---|---|
void |
checkInitialization(InitializableProblemHandler handler) |
java.util.Set<MediaType> |
getSupportedMimes()
The mimes supported by this recogniser
|
void |
initialize(java.util.Map<java.lang.String,Param> params)
This is the hook for configuring the recogniser
|
boolean |
isAvailable()
Is this service available
|
java.util.List<CaptionObject> |
recognise(java.io.InputStream stream,
org.xml.sax.ContentHandler handler,
Metadata metadata,
ParseContext context)
Recognise the objects in the stream
|
public java.util.Set<MediaType> getSupportedMimes()
ObjectRecognisergetSupportedMimes in interface ObjectRecogniserpublic boolean isAvailable()
ObjectRecogniserisAvailable in interface ObjectRecognisertrue when the service is available, false otherwisepublic void initialize(java.util.Map<java.lang.String,Param> params) throws TikaConfigException
ObjectRecogniserinitialize in interface Initializableinitialize in interface ObjectRecogniserparams - configuration instance in the form of contextTikaConfigException - when there is an issue with configurationpublic void checkInitialization(InitializableProblemHandler handler) throws TikaConfigException
checkInitialization in interface Initializablehandler - if there is a problem and no
custom initializableProblemHandler has been configured
via Initializable parameters,
this is called to respond.TikaConfigExceptionpublic java.util.List<CaptionObject> recognise(java.io.InputStream stream, org.xml.sax.ContentHandler handler, Metadata metadata, ParseContext context) throws java.io.IOException, org.xml.sax.SAXException, TikaException
ObjectRecogniserrecognise in interface ObjectRecogniserstream - content streamhandler - tika's content handlermetadata - metadata instancecontext - parser contextRecognisedObjectsjava.io.IOException - when an I/O error occursorg.xml.sax.SAXException - when an issue with XML occursTikaException - any generic errorCopyright © 2010 - 2023 Adobe. All Rights Reserved