public class BilingualDictionaryService extends AbstractBilingualDictionaryWithLongestMatchSearchService
ALL_MATCHINGMETHODS, EMPTY_LANGUAGEPAIRS, EMPTY_LANGUAGEPATHS, EMPTY_LANGUAGES, MINIMUM_MATCHINGMETHODS
Constructor and Description |
---|
BilingualDictionaryService() |
BilingualDictionaryService(ServiceContext serviceContext) |
Modifier and Type | Method and Description |
---|---|
protected Calendar |
doGetLastUpdate() |
protected Collection<Translation> |
doSearch(Language headLang,
Language targetLang,
String headword,
MatchingMethod matchingMethod)
Searches the bilingual dictionary using the specified search term(s) and matching method, and returns bilingual translation.
|
protected Collection<TranslationWithPosition> |
doSearchLongestMatchingTerms(Language headLang,
Language targetLang,
Morpheme[] morphemes) |
void |
setConnectionParameters(ConnectionParameters conParams) |
void |
setDateColumnName(String dateColumnName) |
void |
setLanguageColumnNames(String languageColumnNames) |
protected void |
setLanguages(String[] languages) |
void |
setMatchingMethods(String matchingMethods) |
void |
setTableName(String tableName) |
void |
setUseQCAlgorithm(boolean useQCAlgorithm) |
clearCache, getSupportedMatchingMethods, isCacheSearchResult, scan, search, searchLongestMatchingTerms, setCacheSearchResult, setCacheTtlSec, setSupportedMatchingMethods
getSupportedLanguagePairCollection, getSupportedLanguagePairs, setSupportedLanguagePairs
acquireSemaphore, checkStartupException, convertLanguagePairs, convertLanguages, 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
getLastUpdate, getSupportedLanguagePairs
public BilingualDictionaryService()
public BilingualDictionaryService(ServiceContext serviceContext)
public void setConnectionParameters(ConnectionParameters conParams)
public void setTableName(String tableName)
public void setLanguageColumnNames(String languageColumnNames)
public void setMatchingMethods(String matchingMethods)
public void setDateColumnName(String dateColumnName)
public void setUseQCAlgorithm(boolean useQCAlgorithm)
protected Collection<Translation> doSearch(Language headLang, Language targetLang, String headword, MatchingMethod matchingMethod) throws InvalidParameterException, ProcessFailedException
AbstractBilingualDictionaryWithLongestMatchSearchService
doSearch
in class AbstractBilingualDictionaryWithLongestMatchSearchService
headLang
- Source language of bilingual translation(RFC3066 compliant)targetLang
- Target language of bilingual translation (RFC3066 compliant)headword
- Bilingual translation search languagematchingMethod
- Search methodInvalidParameterException
- One of either headLang,targetLang,matchingMethod is null or else is an empty string. headLang or targetLang do not comply with RFC3066.String not provided for by matchingMethodProcessFailedException
- Bilingual translation search failed due to some causeprotected Collection<TranslationWithPosition> doSearchLongestMatchingTerms(Language headLang, Language targetLang, Morpheme[] morphemes) throws InvalidParameterException, ProcessFailedException
protected Calendar doGetLastUpdate() throws ProcessFailedException
doGetLastUpdate
in class AbstractBilingualDictionaryWithLongestMatchSearchService
ProcessFailedException
protected void setLanguages(String[] languages)