public class SimpleTB extends Object
| Constructor and Description |
|---|
SimpleTB(LocaleId srcLoc,
LocaleId trgLoc) |
| Modifier and Type | Method and Description |
|---|---|
Entry |
addEntry(String srcTerm,
String trgTerm) |
List<TermHit> |
getExistingStrings(TextFragment frag,
LocaleId fragmentLoc,
LocaleId otherLoc) |
List<TermHit> |
getExistingTerms(TextFragment frag,
LocaleId fragmentLoc,
LocaleId otherLoc) |
void |
guessAndImport(File file) |
void |
importCSV(File file) |
void |
importTBX(File file) |
void |
importTSV(File file) |
void |
initialize(boolean stringSearch,
boolean betweenCodes) |
static boolean |
isValidMatch(StringBuilder text,
String stringToMatch,
Range location,
boolean betweenCodes)
Searches for a given string in a text.
|
void |
load(String path) |
void |
removeAll() |
void |
save(String path) |
public void initialize(boolean stringSearch,
boolean betweenCodes)
public void guessAndImport(File file)
public void importTBX(File file)
public void importCSV(File file)
public void importTSV(File file)
public void removeAll()
public List<TermHit> getExistingStrings(TextFragment frag, LocaleId fragmentLoc, LocaleId otherLoc)
public static boolean isValidMatch(StringBuilder text, String stringToMatch, Range location, boolean betweenCodes)
text - Text where to search the strings.stringToMatch - the string to search for.location - location of the term.public List<TermHit> getExistingTerms(TextFragment frag, LocaleId fragmentLoc, LocaleId otherLoc)
public void save(String path)
public void load(String path)
Copyright © 2018. All rights reserved.