public abstract class AbstractKeyphraseExtractService extends AbstractLanguageService implements KeyphraseExtractService
ALL_MATCHINGMETHODS, EMPTY_LANGUAGEPAIRS, EMPTY_LANGUAGEPATHS, EMPTY_LANGUAGES, MINIMUM_MATCHINGMETHODS
Constructor and Description |
---|
AbstractKeyphraseExtractService()
Constructor that doesn't take parameter(s).
|
AbstractKeyphraseExtractService(Collection<Language> supportedLanguages)
Constructor that takes the supported language as a parameter.
|
AbstractKeyphraseExtractService(ServiceContext serviceContext,
Collection<Language> supportedLanguages)
Constructor that takes the service context and supported language as a parameter(s).
|
Modifier and Type | Method and Description |
---|---|
protected abstract Collection<Keyphrase> |
doExtract(Language language,
String text) |
Keyphrase[] |
extract(String language,
String text) |
int |
getMaxSourceLength() |
void |
setMaxSourceLength(int maxSourceLength) |
getSupportedLanguageCollection, getSupportedLanguagePairCollection, getSupportedLanguages, setSupportedLanguageCollection, setSupportedLanguages
acquireSemaphore, checkStartupException, convertLanguagePairs, convertLanguages, doGetLastUpdate, getCurrentServiceContext, getDoDoubleSearch, getEliminateDuplicates, getInitParameter, getInitParameterBoolean, getInitParameterInt, getInitParameterLong, getInitParameters, getInitParameterString, getInitParameterUsingTransformer, getLastUpdate, getLogListener, getMaxResults, getMaxWaitMillisForExternalProcess, getRequestMimeHeaders, getServiceContext, getWorkDirectory, getWorkFile, log, parseDateMacro, processEnd, processEnd, processLap, processStart, releaseSemaphore, setCurrentServiceContext, setDoubleSearchResults, setEliminateDuplicates, setLogListener, setMaxResults, setMaxThreads, setMaxWaitMillisForExternalProcess, setMaxWaitMillisForThread, setMeasureProcessTime, setProcessTimeWarningThreasholdMillis, setStartupException
getComponentServiceFactory, getFile, getServiceName, setComponentServiceFactory, setServiceName
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getSupportedLanguages
public AbstractKeyphraseExtractService()
public AbstractKeyphraseExtractService(Collection<Language> supportedLanguages)
supportedLanguages
- Set of supported languagespublic AbstractKeyphraseExtractService(ServiceContext serviceContext, Collection<Language> supportedLanguages)
serviceContext
- Service contextsupportedLanguages
- Set of supported languagespublic int getMaxSourceLength()
public void setMaxSourceLength(int maxSourceLength)
public Keyphrase[] extract(String language, String text) throws AccessLimitExceededException, InvalidParameterException, LanguageNotUniquelyDecidedException, NoAccessPermissionException, ProcessFailedException, NoValidEndpointsException, ServerBusyException, ServiceNotActiveException, ServiceNotFoundException, UnsupportedLanguageException
extract
in interface KeyphraseExtractService
AccessLimitExceededException
InvalidParameterException
LanguageNotUniquelyDecidedException
NoAccessPermissionException
ProcessFailedException
NoValidEndpointsException
ServerBusyException
ServiceNotActiveException
ServiceNotFoundException
UnsupportedLanguageException
protected abstract Collection<Keyphrase> doExtract(Language language, String text) throws InvalidParameterException, ProcessFailedException