public abstract class AbstractAlchemyExtractor extends AbstractExtractor
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
AAPI_SCHEMA_BASE |
static java.lang.String |
ALCHEMY_ACTION_SI |
static java.lang.String |
ALCHEMY_CATEGORY_SCORE_SI |
static java.lang.String |
ALCHEMY_CATEGORY_SI |
static java.lang.String |
ALCHEMY_ENTITY_RELEVANCE_SI |
static java.lang.String |
ALCHEMY_ENTITY_SI |
static java.lang.String |
ALCHEMY_ENTITY_TYPE_SI |
static java.lang.String |
ALCHEMY_IMAGE_KEYWORD_SI |
static java.lang.String |
ALCHEMY_KEYWORD_SI |
static java.lang.String |
ALCHEMY_LANGUAGE_SI |
static java.lang.String |
ALCHEMY_OBJECT_SI |
static java.lang.String |
ALCHEMY_RELATION_SI |
static java.lang.String |
ALCHEMY_SCORE_SI |
static java.lang.String |
ALCHEMY_SCORE_TYPE_SI |
static java.lang.String |
ALCHEMY_SENTIMENT_SCORE_SI |
static java.lang.String |
ALCHEMY_SENTIMENT_TYPE_SI |
static java.lang.String |
ALCHEMY_SI |
static java.lang.String |
ALCHEMY_SUBJECT_SI |
static java.lang.String |
ALCHEMY_TENSE_SI |
static java.lang.String |
ALCHEMY_URL |
static java.lang.String |
ALCHEMY_VERB_SI |
private static java.lang.String |
apikey |
private java.lang.String[] |
contentTypes |
protected java.lang.String |
defaultEncoding |
static java.lang.String |
DOCUMENT_SI |
protected boolean |
EXTRACT_RELEVANCE |
static java.lang.String |
FACE_DETECTION_AGE_SI |
static java.lang.String |
FACE_DETECTION_GENDER_SI |
static java.lang.String |
FACE_DETECTION_IDENTITY_SI |
static java.lang.String |
FACE_DETECTION_IDENTITY_SUBTYPE_SI |
static java.lang.String |
FACE_DETECTION_POSITION_SI |
static java.lang.String |
FACE_DETECTION_SI |
static java.lang.String |
FACE_DETECTION_SIZE_SI |
static java.lang.String |
FACE_DETECTION_TYPE_HIERARCHY_CHILD_SI |
static java.lang.String |
FACE_DETECTION_TYPE_HIERARCHY_PARENT_SI |
static java.lang.String |
FACE_DETECTION_TYPE_HIERARCHY_SI |
static java.lang.String |
GEO_SI |
static java.lang.String |
IMAGE_SI |
static java.lang.String |
LANG |
static java.lang.String |
SAME_AS_SI |
static java.lang.String |
SOURCE_SI |
static java.lang.String |
SUBTYPE_SI |
static java.lang.String |
TOPIC_SI |
CUSTOM_EXTRACTOR, DONE_FAILED, DONE_MANY, DONE_ONE, EXACTLY_GIVEN_URLS, FILE_EXTRACTOR, FILE_PATTERN, GIVEN_URLS_AND_ALL_CRAWLED_DOCUMENTS, GIVEN_URLS_AND_CRAWLED_DOCUMENTS_IN_URL_DOMAIN, GIVEN_URLS_AND_LINKED_DOCUMENTS, GIVEN_URLS_AND_URL_BELOW, INFO_WAIT_WHILE_WORKING, LOG_TITLE, POINT_START_URL_TEXT, RAW_EXTRACTOR, SELECT_DIALOG_TITLE, STRING_EXTRACTOR_NOT_SUPPORTED_MESSAGE, URL_EXTRACTOR
CLOSE, EXECUTE, INVISIBLE, VISIBLE, WAIT
RETURN_ERROR, RETURN_INFO
Constructor and Description |
---|
AbstractAlchemyExtractor() |
_extractTopicsFrom, _extractTopicsFrom, _extractTopicsFrom, acceptBrowserExtractRequest, addCrawlerUrl, browserExtractorConsumesPlainText, buildSI, buildSL, clearMasterSubject, createAssociation, createAssociation, createTopic, createTopic, createTopic, createTopic, createTopic, createTopic, createTopic, croppedFilename, croppedFilename, croppedUrlString, croppedUrlString, dropExtract, dropExtract, dropExtract, execute, extractTopicsFrom, extractTopicsFrom, extractTopicsFrom, extractTopicsFrom, extractTopicsFromText, getBrowserExtractorName, getCrawlerMode, getDescription, getExtractorType, getForceContent, getForceFiles, getForceUrls, getGUIText, getGUIText, getInterruptsHandled, getMasterSubject, getName, getWandora, handle, handleContent, handleCustomType, handleFiles, handleForcedContent, handleInterrupt, handleStringContent, handleUrls, initializeCustomType, instantDropHandle, makeSubclassOfWandoraClass, runInOwnThread, setData, setDisplayName, setForceContent, setForceFiles, setForceUrls, setMasterSubject, setMasterSubject, setTopicMap, setupCrawler, setWandora, takeNap, urlEncode, useTempTopicMap
addUndoMarker, addUndoMarker, allowMultipleInvocations, clearAllThreads, clearThreads, clearThreads, clearToolLock, clearToolLock, clearToolLocks, execute, execute, forceStop, forceStop, getContext, getCurrentLogger, getDefaultLogger, getHistory, getLastLogger, getState, getThreads, getThreads, getToolMenuItem, getToolMenuItem, getTopicName, hlog, initialize, interruptAllThreads, interruptThreads, interruptThreads, isRunning, isRunning, lockLog, log, log, log, log, requiresRefresh, run, setContext, setDefaultLogger, setLogTitle, setProgress, setProgressMax, setState, setToolLogger, singleLog, singleLog, singleLog, solveContextTopicMap, solveNameForTopicMap
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
execute, execute, getContext, getToolMenuItem, hlog, initialize, isRunning, log, log, log, log, requiresRefresh, setContext, setToolLogger
forceStop, getHistory, getState, lockLog, setLogTitle, setProgress, setProgressMax, setState
protected boolean EXTRACT_RELEVANCE
protected java.lang.String defaultEncoding
public static java.lang.String LANG
public static final java.lang.String ALCHEMY_URL
public static final java.lang.String SOURCE_SI
public static final java.lang.String DOCUMENT_SI
public static final java.lang.String IMAGE_SI
public static final java.lang.String TOPIC_SI
public static final java.lang.String ALCHEMY_SI
public static final java.lang.String ALCHEMY_ENTITY_SI
public static final java.lang.String ALCHEMY_ENTITY_TYPE_SI
public static final java.lang.String ALCHEMY_ENTITY_RELEVANCE_SI
public static final java.lang.String ALCHEMY_IMAGE_KEYWORD_SI
public static final java.lang.String ALCHEMY_KEYWORD_SI
public static final java.lang.String ALCHEMY_CATEGORY_SI
public static final java.lang.String ALCHEMY_CATEGORY_SCORE_SI
public static final java.lang.String ALCHEMY_LANGUAGE_SI
public static final java.lang.String ALCHEMY_SENTIMENT_TYPE_SI
public static final java.lang.String ALCHEMY_SENTIMENT_SCORE_SI
public static final java.lang.String AAPI_SCHEMA_BASE
public static final java.lang.String SUBTYPE_SI
public static final java.lang.String GEO_SI
public static final java.lang.String SAME_AS_SI
public static final java.lang.String ALCHEMY_SCORE_SI
public static final java.lang.String ALCHEMY_SCORE_TYPE_SI
public static final java.lang.String ALCHEMY_SUBJECT_SI
public static final java.lang.String ALCHEMY_ACTION_SI
public static final java.lang.String ALCHEMY_OBJECT_SI
public static final java.lang.String ALCHEMY_RELATION_SI
public static final java.lang.String ALCHEMY_VERB_SI
public static final java.lang.String ALCHEMY_TENSE_SI
public static final java.lang.String FACE_DETECTION_SI
public static final java.lang.String FACE_DETECTION_POSITION_SI
public static final java.lang.String FACE_DETECTION_SIZE_SI
public static final java.lang.String FACE_DETECTION_GENDER_SI
public static final java.lang.String FACE_DETECTION_AGE_SI
public static final java.lang.String FACE_DETECTION_IDENTITY_SI
public static final java.lang.String FACE_DETECTION_TYPE_HIERARCHY_SI
public static final java.lang.String FACE_DETECTION_IDENTITY_SUBTYPE_SI
public static final java.lang.String FACE_DETECTION_TYPE_HIERARCHY_PARENT_SI
public static final java.lang.String FACE_DETECTION_TYPE_HIERARCHY_CHILD_SI
private final java.lang.String[] contentTypes
private static java.lang.String apikey
public javax.swing.Icon getIcon()
AbstractWandoraTool
getIcon
should return Icon
object of
the tool.getIcon
in interface WandoraTool
getIcon
in class AbstractExtractor
public WandoraToolType getType()
AbstractWandoraTool
Tool type is used to categorize tools. Tool type has no real effect today, it is merely an informative property of a tool.
getType
in interface WandoraTool
getType
in class AbstractExtractor
public java.lang.String[] getContentTypes()
Handler
ContentHandler
can process.getContentTypes
in interface Handler
getContentTypes
in class AbstractExtractor
public boolean useURLCrawler()
useURLCrawler
in class AbstractExtractor
public static java.lang.String sendRequest(java.net.URL url, java.lang.String data, java.lang.String ctype, java.lang.String method) throws java.io.IOException
java.io.IOException
public boolean isConfigurable()
AbstractWandoraTool
isConfigurable
in interface WandoraTool
isConfigurable
in class AbstractWandoraTool
public void configure(Wandora admin, Options options, java.lang.String prefix) throws TopicMapException
AbstractWandoraTool
configure
in interface WandoraTool
configure
in class AbstractWandoraTool
TopicMapException
public void writeOptions(Wandora admin, Options options, java.lang.String prefix)
AbstractWandoraTool
writeOptions
in interface WandoraTool
writeOptions
in class AbstractWandoraTool
public abstract boolean _extractTopicsFrom(java.io.InputStream in, TopicMap topicMap) throws java.lang.Exception
java.lang.Exception
public java.lang.String doBrowserExtract(BrowserExtractRequest request, Wandora wandora) throws TopicMapException
doBrowserExtract
in interface BrowserPluginExtractor
doBrowserExtract
in class AbstractExtractor
TopicMapException
public java.lang.String solveTitle(java.lang.String content)
public void fillDocumentTopic(Topic textTopic, TopicMap topicMap, java.lang.String content)
public void fillImageTopic(Topic imageTopic, TopicMap topicMap, java.awt.image.BufferedImage image)
public void createSameAsAssociationWith(java.lang.String sameAsIdentifier, Topic topic, Topic topicType, TopicMap tm)
public Topic getEntityTypeTopic(java.lang.String entityType, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getEntityTopic(java.lang.String entity, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getKeywordTopic(java.lang.String keyword, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getCategoryTopic(java.lang.String category, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getCategoryScoreTopic(java.lang.String categoryScore, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getLanguageTopic(java.lang.String language, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getRelevanceTopic(java.lang.String relevance, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getSentimentTypeTopic(java.lang.String str, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getSentimentScoreTopic(java.lang.String str, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getScoreTopic(java.lang.String str, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getSubjectTopic(java.lang.String subject, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getActionTopic(java.lang.String action, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getObjectTopic(java.lang.String object, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getVerbTopic(java.lang.String verb, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getTenseTopic(java.lang.String tense, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionTopic(TopicMap tm, Topic imageTopic) throws TopicMapException
TopicMapException
public Topic getFaceDetectionGenderTopic(java.lang.String gender, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionAgeTopic(java.lang.String age, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionIdentityTopic(java.lang.String name, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionIdentitySubtypeTopic(java.lang.String subtype, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionTypeHierarchyTopic(java.lang.String type, TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionTypeHierarchyParent(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionTypeHierarchyChild(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionPositionType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionSizeType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionGenderType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionAgeType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionIdentityType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionTypeHierarchyType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getFaceDetectionIdentitySubtypeType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getRelevanceType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getEntityTypeType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getEntityType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getSubjectType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getActionType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getObjectType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getRelationType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getVerbType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getTenseType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getKeywordType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getImageKeywordType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getScoreType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getCategoryType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getLanguageType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getCategoryScoreType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getSentimentTypeType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getSentimentScoreType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getSameAsType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getWandoraClass(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getTopicType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getSourceType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getAlchemyType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getDocumentType(TopicMap tm) throws TopicMapException
TopicMapException
public Topic getImageType(TopicMap tm) throws TopicMapException
TopicMapException
protected Topic getOrCreateTopic(TopicMap tm, java.lang.String si) throws TopicMapException
TopicMapException
protected Topic getOrCreateTopic(TopicMap tm, java.lang.String si, java.lang.String bn) throws TopicMapException
TopicMapException
protected Topic getOrCreateTopic(TopicMap tm, java.lang.String si, java.lang.String bn, Topic type) throws TopicMapException
TopicMapException
protected void makeSubclassOf(TopicMap tm, Topic t, Topic superclass) throws TopicMapException
TopicMapException
public java.lang.String solveAPIKey(Wandora wandora)
public java.lang.String solveAPIKey()
public void forgetAuthorization()
protected java.lang.String getStringFromDocument(org.w3c.dom.Document doc)
protected java.lang.String getFileContents(java.io.File file) throws java.io.IOException, java.io.FileNotFoundException
java.io.IOException
java.io.FileNotFoundException
protected boolean isValid(java.lang.String str)
Copyright 2004-2015 Wandora Team