public class BilingualFileConnector extends PensieveTMConnector
PensieveTMConnector to allow one-step leveraging
from a bilingual file. Upon initialization it imports the specified input file
into a temporary Pensieve TM, and points its superclass to it. All actual queries
are handled by the superclass.| Constructor and Description |
|---|
BilingualFileConnector() |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes this connector.
|
String |
getName()
Gets the name of the connector.
|
Parameters |
getParameters()
Gets the current parameters of this connector.
|
String |
getSettingsDisplay()
Gets a display representation of the current settings for this connector.
|
void |
open()
Opens this query engine.
|
int |
query(String plainText)
Starts a query for a give plain text.
|
int |
query(TextFragment text)
Starts a query for a given text.
|
void |
setLanguages(LocaleId sourceLocale,
LocaleId targetLocale)
Sets the source and target languages for this query engine.
|
void |
setParameters(IParameters params)
Sets the parameters for opening and querying this connector.
|
clearAttributes, getMaximumHits, getThreshold, hasNext, next, removeAttribute, setAttribute, setMaximumHits, setRootDirectory, setThresholdbatchLeverage, batchLeverageUsingBatchQuery, batchQuery, batchQueryText, getNoQueryThreshold, getSourceLanguage, getTargetLanguage, getWeight, leverage, leverageUsingBatchQuery, setNoQueryThreshold, setWeight, toInternalCodeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitbatchLeverage, batchQuery, batchQueryText, getNoQueryThreshold, getSourceLanguage, getTargetLanguage, getWeight, leverage, setNoQueryThreshold, setWeightforEachRemaining, removepublic String getName()
IQuerygetName in interface IQuerygetName in class PensieveTMConnectorpublic String getSettingsDisplay()
IQuerygetSettingsDisplay in interface IQuerygetSettingsDisplay in class PensieveTMConnectorpublic int query(String plainText)
IQueryquery in interface IQueryquery in class PensieveTMConnectorplainText - text to query.public int query(TextFragment text)
IQueryquery in interface IQueryquery in class PensieveTMConnectortext - The text to query.public void open()
IQueryopen in interface IQueryopen in class PensieveTMConnectorpublic void close()
IQueryclose in interface AutoCloseableclose in interface IQueryclose in class PensieveTMConnectorpublic void setLanguages(LocaleId sourceLocale, LocaleId targetLocale)
IQuerysetLanguages in interface IQuerysetLanguages in class PensieveTMConnectorsourceLocale - Code of the source locale.targetLocale - Code of the target locale.public Parameters getParameters()
IQuerygetParameters in interface IQuerygetParameters in class PensieveTMConnectorpublic void setParameters(IParameters params)
IQuerysetParameters in interface IQuerysetParameters in class PensieveTMConnectorparams - the parameters to set.Copyright © 2021. All rights reserved.