public class KantanMTv21Connector extends BaseConnector
open() method.| Modifier and Type | Class and Description |
|---|---|
protected static class |
KantanMTv21Connector.RequestInfo
Wrapper to hold the original fragment along with its extracted codes, so
that we can reinsert them into the translated target.
|
| Modifier and Type | Field and Description |
|---|---|
static String |
STATE_INITIALISING |
static String |
STATE_OFFLINE |
static String |
STATE_RUNNING |
static String |
STATE_TERMINATING |
| Constructor and Description |
|---|
KantanMTv21Connector() |
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
batchQuery(List<TextFragment> fragments) |
void |
close() |
String |
getEngines()
Gets the information about the available engines.
|
String |
getEngineStatus(String engine)
Get the status of an engine.
|
String |
getName() |
IParameters |
getParameters() |
String |
getSettingsDisplay() |
boolean |
hasNext() |
QueryResult |
next() |
void |
open() |
int |
query(String plainText) |
int |
query(TextFragment tf) |
String |
startEngine(String engine)
Starts an engine (do nothing if it's already started).
|
String |
stopEngine(String engine)
Stops an engine (do nothing if it's already stopped).
|
protected String |
toInternalCode(LocaleId locId) |
batchLeverage, batchLeverageUsingBatchQuery, batchQueryText, clearAttributes, getNoQueryThreshold, getSourceLanguage, getTargetLanguage, getWeight, leverage, leverageUsingBatchQuery, removeAttribute, setAttribute, setLanguages, setNoQueryThreshold, setParameters, setRootDirectory, setWeightclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemaining, removepublic static final String STATE_OFFLINE
public static final String STATE_RUNNING
public static final String STATE_INITIALISING
public static final String STATE_TERMINATING
public String getName()
public String getSettingsDisplay()
public void open()
public void close()
public IParameters getParameters()
getParameters in interface IQuerygetParameters in class BaseConnectorprotected String toInternalCode(LocaleId locId)
toInternalCode in class BaseConnectorpublic int query(String plainText)
public int query(TextFragment tf)
public boolean hasNext()
hasNext in interface Iterator<QueryResult>hasNext in interface IQueryhasNext in class BaseConnectorpublic QueryResult next()
next in interface Iterator<QueryResult>next in interface IQuerynext in class BaseConnectorpublic List<List<QueryResult>> batchQuery(List<TextFragment> fragments)
batchQuery in interface IQuerybatchQuery in class BaseConnectorpublic String getEngines()
public String getEngineStatus(String engine)
engine - the name of the engine to check.public String startEngine(String engine)
engine - the name of the engine to start.Copyright © 2019. All rights reserved.