| Modifier and Type | Method and Description |
|---|---|
static int |
RenumberingUtil.calculateCodeOffset(TextFragment tf)
Find the minimum ID of any code in the TextFragment, then
use that to calculate the offset/delta by which all code
IDs in the TextFragment need to be adjusted.
|
static boolean |
RenumberingUtil.containsOnlyMatchingCodes(TextFragment tf)
Check to see if this text fragment contains either open or closed
tags that do not have a corresponding paired tag within the same
TextFragment.
|
| Modifier and Type | Method and Description |
|---|---|
AltTranslation |
AltTranslationsAnnotation.add(LocaleId sourceLocId,
LocaleId targetLocId,
TextFragment originalSource,
TextFragment alternateSource,
TextFragment alternateTarget,
MatchType type,
int combinedScore,
String origin)
Adds a new entry to the list of alternate translations.
|
AltTranslation |
AltTranslationsAnnotation.add(LocaleId sourceLocId,
LocaleId targetLocId,
TextFragment originalSource,
TextFragment alternateSource,
TextFragment alternateTarget,
MatchType type,
int combinedScore,
String origin,
int fuzzyScore,
int qualityScore)
Adds a new entry to the list of alternate translations.
|
void |
AltTranslation.setTarget(LocaleId targetLocId,
TextFragment alternateTarget)
Sets the target parts of this alternate translation.
|
| Constructor and Description |
|---|
AltTranslation(LocaleId sourceLocId,
LocaleId targetLocId,
TextFragment originalSource,
TextFragment alternateSource,
TextFragment alternateTarget,
MatchType type,
int combinedScore,
String origin)
Creates a new AltTranslation object.
|
AltTranslation(LocaleId sourceLocId,
LocaleId targetLocId,
TextFragment originalSource,
TextFragment alternateSource,
TextFragment alternateTarget,
MatchType type,
int combinedScore,
String origin,
int fuzzyScore,
int qualityScore)
Creates a new AltTranslation object.
|
| Modifier and Type | Method and Description |
|---|---|
void |
InlineCodeFinder.process(TextFragment fragment)
Applies the rules to a given content and converts all matching sections
into in-line codes.
|
| Modifier and Type | Method and Description |
|---|---|
static TextFragment |
GenericContent.fromLetterCodedToFragment(String text,
TextFragment fragment,
boolean reuseCodes)
Deprecated.
|
static TextFragment |
GenericContent.fromLetterCodedToFragment(String text,
TextFragment fragment,
boolean reuseCodes,
boolean decodeEncodedLetterCodes)
Converts a letter-coded text to a fragment.
|
| Modifier and Type | Method and Description |
|---|---|
static String |
GenericContent.fromFragmentToLetterCoded(TextFragment fragment)
Deprecated.
|
static String |
GenericContent.fromFragmentToLetterCoded(TextFragment fragment,
boolean encodeExistingLetterCodes)
Converts a text fragment into a letter-coded text, optionally escaping
tags that will interfere with conversion back to a fragment.
|
static TextFragment |
GenericContent.fromLetterCodedToFragment(String text,
TextFragment fragment,
boolean reuseCodes)
Deprecated.
|
static TextFragment |
GenericContent.fromLetterCodedToFragment(String text,
TextFragment fragment,
boolean reuseCodes,
boolean decodeEncodedLetterCodes)
Converts a letter-coded text to a fragment.
|
XLIFFContent |
XLIFFContent.setContent(TextFragment content)
Sets the fragment to format.
|
TMXContent |
TMXContent.setContent(TextFragment content)
Sets the fragment to format.
|
GenericContent |
GenericContent.setContent(TextFragment content) |
XLIFFContent |
XLIFFContent.setContent(TextFragment content,
boolean resetStandoff)
Sets the fragment to format.
|
static void |
GenericContent.updateFragment(String genericText,
TextFragment fragment,
boolean allowCodeDeletion)
Updates a text fragment from a generic representation.
|
void |
TMXWriter.writeAlternate(AltTranslation alt,
TextFragment srcOriginal)
Writes the data of an
AltTranslation to this TMX output. |
protected void |
TMXWriter.writeResourceLevelProperties(Set<String> names,
ITextUnit item,
TextFragment srcSegment) |
void |
TMXWriter.writeTU(TextFragment source,
TextFragment target,
String tuid,
Map<String,String> attributes)
Writes a TMX TU element.
|
void |
TMXWriter.writeTU(TextFragment source,
TextFragment target,
String tuid,
Map<String,String> attributes,
LocaleId altTrgLoc)
Writes a TMX TU element.
|
protected void |
TMXWriter.writeTUV(TextFragment frag,
LocaleId locale,
TextContainer contForProp)
Writes a TUV element.
|
| Constructor and Description |
|---|
GenericContent(TextFragment content) |
TMXContent(TextFragment content)
Creates a new TMXContent object and set its content to the given fragment.
|
XLIFFContent(TextFragment content)
Creates a new XLIFFContent object and set its content to the given fragment.
|
| Modifier and Type | Field and Description |
|---|---|
TextFragment |
QueryResult.source
Text of the source for this result.
|
TextFragment |
QueryResult.target
Text of the target for this result.
|
| Modifier and Type | Method and Description |
|---|---|
int |
IQuery.query(TextFragment text)
Starts a query for a given text.
|
AltTranslation |
QueryResult.toAltTranslation(TextFragment originalSource,
LocaleId sourceLocId,
LocaleId targetLocId)
Convert a QueryResult to an
AltTranslation |
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
IQuery.batchQuery(List<TextFragment> fragments)
Starts a batch query for a given list of
TextFragments. |
| Modifier and Type | Field and Description |
|---|---|
TextFragment |
AnnotatedSpan.span
Copy of the fragment of text to which the annotation is applied.
|
TextFragment |
TextPart.text
Text fragment of this part.
|
| Modifier and Type | Method and Description |
|---|---|
TextFragment |
TextFragment.append(char value)
Appends a character to the fragment.
|
TextFragment |
TextFragment.append(CharSequence csq)
Appends the specified character sequence to this fragment.
|
TextFragment |
TextFragment.append(CharSequence csq,
int start,
int end)
Appends a subsequence of the specified character sequence to this fragment.
|
TextFragment |
TextFragment.append(Code code)
Appends an existing code to this fragment.
|
TextFragment |
TextFragment.append(String text)
Appends a string to the fragment.
|
TextFragment |
TextFragment.append(TextFragment fragment)
Appends a TextFragment object to this fragment.
|
TextFragment |
TextFragment.append(TextFragment fragment,
boolean keepCodeIds)
Appends a TextFragment object to this fragment.
|
TextFragment |
TextFragment.cleanCodes()
Removes all codes both in the Codes list and the markers.
|
TextFragment |
TextFragment.clone()
Clones this TextFragment.
|
TextFragment |
TextContainer.createJoinedContent() |
static TextFragment |
TextUnitUtil.expandCodes(TextFragment tf)
Expand codes that have been previously merged.
|
static TextFragment |
TextUnitUtil.extractSegMarkers(TextFragment tf,
TextFragment original,
boolean removeFromOriginal)
Extracts segment and text part markers from a given string, creates codes (place-holder type) for those markers,
and appends them to a given text fragment.
|
TextFragment |
TextPart.getContent()
Gets the text fragment for this part.
|
TextFragment |
TextContainer.getFirstContent()
Gets the content of the first part (segment or non-segment) of this container.
|
TextFragment |
Segments.getFirstContent() |
TextFragment |
ISegments.getFirstContent()
Gets the content of the first segment of this container.
|
TextFragment |
TextContainer.getLastContent()
Gets the content of the last part (segment or non-segment) of this container.
|
TextFragment |
Segments.getLastContent() |
TextFragment |
ISegments.getLastContent()
Gets the content of last segment of this container.
|
TextFragment |
TextContainer.getUnSegmentedContentCopy()
Gets a new TextFragment representing the un-segmented content of this container.
|
static TextFragment |
TextFragmentUtil.removeMoreThanMaxCodes(TextFragment tf) |
TextFragment |
TextUnit.setSourceContent(TextFragment content) |
TextFragment |
ITextUnit.setSourceContent(TextFragment content)
Sets the content of the source for this TextUnit.
|
TextFragment |
TextUnit.setTargetContent(LocaleId locId,
TextFragment content) |
TextFragment |
ITextUnit.setTargetContent(LocaleId locId,
TextFragment content)
Sets the content of the target for a given locale for this TextUnit.
|
TextFragment[] |
CodeSimplifier.simplifyAll(TextContainer tc,
boolean removeLeadingTrailingCodes,
boolean mergeCodes)
Simplifies all possible tags in a given possibly segmented text container.
|
TextFragment[] |
CodeSimplifier.simplifyAll(TextFragment tf,
boolean removeLeadingTrailingCodes)
Simplifies all possible tags in a given text fragment.
|
TextFragment[] |
CodeSimplifier.simplifyAll(TextFragment tf,
boolean removeLeadingTrailingCodes,
boolean mergeCodes)
Simplifies all possible tags in a given text fragment.
|
TextFragment[] |
CodeSimplifier.simplifyAll(TextFragment tf,
int maxIterations,
boolean removeLeadingTrailingCodes,
boolean mergeCodes)
Simplifies all possible tags in a given text fragment.
|
static TextFragment[] |
TextUnitUtil.simplifyCodes(TextContainer tc,
String rules,
boolean removeLeadingTrailingCodes)
Simplifies all possible tags in a given text container.
|
static TextFragment[] |
TextUnitUtil.simplifyCodes(TextContainer tc,
String rules,
boolean removeLeadingTrailingCodes,
boolean mergeCodes)
Simplifies all possible tags in a given text container.
|
static TextFragment[] |
TextUnitUtil.simplifyCodes(TextFragment tf,
String rules,
boolean removeLeadingTrailingCodes)
Simplifies all possible tags in a given text fragment.
|
static TextFragment[] |
TextUnitUtil.simplifyCodes(TextFragment tf,
String rules,
boolean removeLeadingTrailingCodes,
boolean mergeCodes)
Simplifies all possible tags in a given text fragment.
|
static TextFragment |
TextUnitUtil.storeSegmentation(TextContainer tc) |
TextFragment |
TextFragment.subSequence(int start,
int end)
Gets a copy of a sub-sequence of this object.
|
| Modifier and Type | Method and Description |
|---|---|
static void |
TextFragmentUtil.addMissingCodes(TextFragment from,
TextFragment to,
CodeMatches codeMatches)
Add missing leading and trailing codes from source (aka "from") to target (aka 'to').
|
static CodeMatches |
TextFragmentUtil.alignAndCopyCodeMetadata(TextFragment from,
TextFragment to)
Update the meta fields in
Code "to" that match those of
"from" But only if the "to" code has empty data. |
static CodeMatches |
TextFragmentUtil.alignAndCopyCodeMetadata(TextFragment from,
TextFragment to,
boolean addMissingCodes)
Update the meta fields in
Code "to" that match those of
"from" But only if the "to" code has empty data (@see{forceCopy}). |
static CodeMatches |
TextFragmentUtil.alignAndCopyCodeMetadata(TextFragment from,
TextFragment to,
boolean addMissingCodes,
boolean forceCopy) |
static CodeMatches |
TextFragmentUtil.alignAndCopyCodeMetadata(TextFragment from,
TextFragment to,
boolean addMissingCodes,
boolean forceCopy,
CodeMatchStrategy strategy)
Update the meta fields in
Code "to" that match those of
"from" But only if the "to" code has empty data (@see{forceCopy}). |
void |
TextFragment.alignCodeIds(TextFragment base) |
void |
TextFragment.alignCodeIds(TextFragment base,
CodeMatchStrategy strategy)
Aligns the code IDs of this fragment with the ones of a given fragment.
|
TextFragment |
TextFragment.append(TextFragment fragment)
Appends a TextFragment object to this fragment.
|
void |
TextContainer.append(TextFragment fragment)
Appends a part at the end of this container.
|
void |
Segments.append(TextFragment fragment) |
void |
ISegments.append(TextFragment fragment)
Appends a TextFragment as a segment at the end of this container.
|
TextFragment |
TextFragment.append(TextFragment fragment,
boolean keepCodeIds)
Appends a TextFragment object to this fragment.
|
void |
TextContainer.append(TextFragment fragment,
boolean collapseIfPreviousEmpty)
Appends a part at the end of this container.
|
void |
Segments.append(TextFragment fragment,
boolean collapseIfPreviousEmpty) |
void |
ISegments.append(TextFragment fragment,
boolean collapseIfPreviousEmpty)
Appends a TextFragment as a segment at the end of this container.
|
void |
TextContainer.append(TextFragment fragment,
boolean collapseIfPreviousEmpty,
boolean keepCodeIds)
Appends a part at the end of this container.
|
int |
TextFragment.compareTo(TextFragment tf)
Compares an object with this TextFragment.
|
int |
TextFragment.compareTo(TextFragment frag,
boolean codeSensitive)
Deprecated.
Use compareTo(TextFragment, CompareMode)
|
int |
TextFragment.compareTo(TextFragment frag,
TextFragment.CompareMode compMode)
Compares with another TextFragment.
|
static void |
TextFragmentUtil.copyCodeMetadata(TextFragment sf,
TextFragment tf,
boolean forceCopy,
CodeMatches cm) |
static void |
TextUnitUtil.deleteLastChar(TextFragment textFragment)
Deletes the last non-whitespace and non-code character of a given text fragment.
|
static boolean |
TextUnitUtil.endsWith(TextFragment textFragment,
String substr)
Indicates if a given text fragment ends with a given sub-string.
|
static TextFragment |
TextUnitUtil.expandCodes(TextFragment tf)
Expand codes that have been previously merged.
|
static TextFragment |
TextUnitUtil.extractSegMarkers(TextFragment tf,
TextFragment original,
boolean removeFromOriginal)
Extracts segment and text part markers from a given string, creates codes (place-holder type) for those markers,
and appends them to a given text fragment.
|
static int |
TextFragment.fromFragmentToString(TextFragment frag,
int pos)
Gets the position in the string representation of a fragment of a given
position in that fragment.
|
static String |
TextUnitUtil.getCodedText(TextFragment textFragment)
Gets text of a given text fragment object possibly containing inline codes.
|
static char |
TextUnitUtil.getLastChar(TextFragment textFragment)
Gets the last character of a given text fragment.
|
static String |
TextUnitUtil.getText(TextFragment textFragment)
Extracts text from the given text fragment.
|
static String |
TextUnitUtil.getText(TextFragment textFragment,
List<Integer> markerPositions)
Extracts text from the given text fragment.
|
static boolean |
TextUnitUtil.hasMergedCode(TextFragment tf) |
void |
TextFragment.insert(int offset,
TextFragment fragment)
Inserts a TextFragment object to this fragment.
|
void |
TextFragment.insert(int offset,
TextFragment fragment,
boolean keepCodeIds)
Inserts a TextFragment object to this fragment.
|
static boolean |
TextUnitUtil.isEmpty(TextFragment textFragment)
Indicates if a given text fragment object is null, or the text it contains is null or empty.
|
static boolean |
TextFragmentUtil.isLeadingCode(Code code,
TextFragment source)
Determine if the code is at the beginning of the
TextFragment without
intervening text. |
static boolean |
TextUnitUtil.isWellformed(TextFragment tf) |
static int |
TextUnitUtil.lastIndexOf(TextFragment textFragment,
String findWhat)
Returns the index (within a given text fragment object) of the rightmost occurrence of the specified substring.
|
static void |
TextFragmentUtil.logCodeMismatchErrors(CodeMatches matches,
TextFragment from,
TextFragment to,
String textUnitId)
Log all code mismatch issues
|
static boolean |
TextFragmentUtil.moreThanMaxCodes(TextFragment tf) |
static String |
TextUnitUtil.printMarkerIndexes(TextFragment textFragment) |
static String |
TextUnitUtil.printMarkers(TextFragment textFragment) |
static void |
TextUnitUtil.removeCodes(TextFragment tf)
Removes all inline tags from the given
TextFragment |
static TextFragment |
TextFragmentUtil.removeMoreThanMaxCodes(TextFragment tf) |
static String |
TextUnitUtil.restoreSegmentation(TextContainer tc,
TextFragment segStorage)
Restores original segmentation of a given text container from a given text fragment created with storeSegmentation().
|
void |
TextPart.setContent(TextFragment fragment)
Sets the
TextFragment for this part. |
void |
TextContainer.setContent(TextFragment content)
Sets the content of this TextContainer.
|
TextFragment |
TextUnit.setSourceContent(TextFragment content) |
TextFragment |
ITextUnit.setSourceContent(TextFragment content)
Sets the content of the source for this TextUnit.
|
TextFragment |
TextUnit.setTargetContent(LocaleId locId,
TextFragment content) |
TextFragment |
ITextUnit.setTargetContent(LocaleId locId,
TextFragment content)
Sets the content of the target for a given locale for this TextUnit.
|
TextFragment[] |
CodeSimplifier.simplifyAll(TextFragment tf,
boolean removeLeadingTrailingCodes)
Simplifies all possible tags in a given text fragment.
|
TextFragment[] |
CodeSimplifier.simplifyAll(TextFragment tf,
boolean removeLeadingTrailingCodes,
boolean mergeCodes)
Simplifies all possible tags in a given text fragment.
|
TextFragment[] |
CodeSimplifier.simplifyAll(TextFragment tf,
int maxIterations,
boolean removeLeadingTrailingCodes,
boolean mergeCodes)
Simplifies all possible tags in a given text fragment.
|
static TextFragment[] |
TextUnitUtil.simplifyCodes(TextFragment tf,
String rules,
boolean removeLeadingTrailingCodes)
Simplifies all possible tags in a given text fragment.
|
static TextFragment[] |
TextUnitUtil.simplifyCodes(TextFragment tf,
String rules,
boolean removeLeadingTrailingCodes,
boolean mergeCodes)
Simplifies all possible tags in a given text fragment.
|
void |
CodeSimplifier.simplifyEmptyOpeningClosing(TextFragment tf) |
void |
CodeSimplifier.simplifyIsolated(TextFragment tf)
Simplifies the place-holders in a given text fragment.
|
void |
CodeSimplifier.simplifyOpeningClosing(TextFragment tf) |
static CodeMatches |
TextFragmentUtil.synchronizeCodeIds(TextFragment from,
TextFragment to) |
static CodeMatches |
TextFragmentUtil.synchronizeCodeIds(TextFragment from,
TextFragment to,
CodeMatchStrategy strategy)
Matches the code IDs of the
from |
static String |
TextUnitUtil.toText(TextFragment tf)
Returns the content of a given text fragment, including the original codes whenever
possible.
|
static String |
TextFragmentUtil.toText(TextFragment tf)
Render the
TextFragment including all Codes. |
static void |
TextUnitUtil.trimLeading(TextFragment textFragment)
Removes leading whitespaces from a given text fragment.
|
static void |
TextUnitUtil.trimLeading(TextFragment textFragment,
GenericSkeleton skel)
Removes leading whitespaces from a given text fragment, puts removed whitespaces to the given skeleton.
|
static void |
TextUnitUtil.trimTrailing(TextFragment textFragment)
Removes trailing whitespaces from a given text fragment.
|
static void |
TextUnitUtil.trimTrailing(TextFragment textFragment,
GenericSkeleton skel)
Removes trailing whitespaces from a given text fragment, puts removed whitespaces to the given skeleton.
|
static void |
TextFragment.unwrap(TextFragment frag)
Unwraps the content of a TextFragment.
|
| Constructor and Description |
|---|
AnnotatedSpan(String type,
InlineAnnotation annotation,
TextFragment span,
int start,
int end)
Creates a new AnnotatedSpan object with a give type of annotation,
its annotation and its fragment of text.
|
CodeMatches(TextFragment from,
TextFragment to) |
Segment(String id,
TextFragment text)
Creates a Segment object with a given identifier and a given
text fragment.
|
TextContainer(TextFragment fragment)
Creates a new TextContainer object with an initial TextFragment.
|
TextFragment(TextFragment fragment)
Creates a TextFragment with the content of a given TextFragment.
|
TextPart(String id,
TextFragment text)
Creates a new TextPart with a given
TextFragment. |
TextPart(TextFragment text)
Creates a new TextPart with a given
TextFragment. |
| Modifier and Type | Method and Description |
|---|---|
String |
GenericSkeletonWriter.getContent(TextFragment tf,
LocaleId locToUse,
EncoderContext context)
Gets the original content of a TextFragment.
|
| Modifier and Type | Method and Description |
|---|---|
int |
ApertiumMTConnector.query(TextFragment fragment)
Queries the Apertium API.
|
| Modifier and Type | Method and Description |
|---|---|
int |
BilingualFileConnector.query(TextFragment text) |
| Modifier and Type | Method and Description |
|---|---|
int |
GlobalSightTMConnector.query(TextFragment frag) |
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
GlobalSightTMConnector.batchQuery(List<TextFragment> fragments) |
| Modifier and Type | Method and Description |
|---|---|
int |
GoogleMTv2Connector.query(TextFragment frag) |
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
GoogleMTv2Connector.batchQuery(List<TextFragment> fragments) |
| Modifier and Type | Method and Description |
|---|---|
int |
GoogleAutoMLTranslationConnector.query(TextFragment sourceFragment) |
| Modifier and Type | Method and Description |
|---|---|
int |
KantanMTv21Connector.query(TextFragment tf) |
int |
KantanMTConnector.query(TextFragment tf)
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
KantanMTv21Connector.batchQuery(List<TextFragment> fragments) |
List<List<QueryResult>> |
KantanMTConnector.batchQuery(List<TextFragment> fragments)
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
int |
Lingo24Connector.query(TextFragment fragment)
Queries the Lingo24 Premium MT API.
|
| Modifier and Type | Method and Description |
|---|---|
int |
MicrosoftMTConnector.query(TextFragment frag) |
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
MicrosoftMTConnector.batchQuery(List<TextFragment> fragments) |
| Modifier and Type | Method and Description |
|---|---|
int |
MMTConnector.query(TextFragment fragment)
Queries the ModernMT API fro the configured server.
|
| Modifier and Type | Method and Description |
|---|---|
int |
MyMemoryTMConnector.query(TextFragment frag) |
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
MyMemoryTMConnector.batchQuery(List<TextFragment> fragments) |
| Modifier and Type | Method and Description |
|---|---|
int |
PensieveTMConnector.query(TextFragment text) |
| Modifier and Type | Method and Description |
|---|---|
int |
TDASearchConnector.query(TextFragment frag) |
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
TDASearchConnector.batchQuery(List<TextFragment> fragments) |
| Modifier and Type | Method and Description |
|---|---|
int |
TranslateToolkitTMConnector.query(TextFragment text) |
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
TranslateToolkitTMConnector.batchQuery(List<TextFragment> fragments) |
| Modifier and Type | Method and Description |
|---|---|
TextFragment[] |
ICMLSkeleton.getMovedParts() |
| Modifier and Type | Method and Description |
|---|---|
void |
ICMLSkeleton.addMovedParts(TextFragment[] movedParts) |
| Modifier and Type | Method and Description |
|---|---|
String |
HTML5SkeletonWriter.getContent(TextFragment tf,
LocaleId locToUse,
EncoderContext context)
Gets the original content of a TextFragment.
|
| Modifier and Type | Method and Description |
|---|---|
TextFragment |
MosesTextFilter.fromPseudoXLIFF(String text)
Converts a pseudoXLIFF string into a TextFragment.
|
| Modifier and Type | Method and Description |
|---|---|
protected String |
TTXSkeletonWriter.processFragment(TextFragment frag,
EncoderContext context)
Outputs a fragment.
|
| Modifier and Type | Method and Description |
|---|---|
protected String |
TXMLSkeletonWriter.processFragment(TextFragment frag,
EncoderContext context)
Outputs a fragment.
|
| Modifier and Type | Method and Description |
|---|---|
TextFragment |
InlineCodeTransformer.serializeTextParts(List<Serializable> parts,
boolean targetIsTKit) |
TextFragment |
InlineCodeTransformer.serializeTextPartsForFilter(List<Serializable> parts) |
TextFragment |
InlineCodeTransformer.serializeTextPartsForTKit(List<Serializable> parts) |
| Modifier and Type | Method and Description |
|---|---|
void |
TextUnitMerger.copyCodeMetadata(TextFragment from,
TextFragment to) |
void |
ITextUnitMerger.copyCodeMetadata(TextFragment from,
TextFragment to)
Update the meta fields in
Code's "to" that match those of
"from" But only if the "to" code has empty data. |
| Modifier and Type | Method and Description |
|---|---|
List<TermHit> |
ITermAccess.getExistingStrings(TextFragment fragment,
LocaleId fragmentLoc,
LocaleId otherLoc) |
List<TermHit> |
ITermAccess.getExistingTerms(TextFragment fragment,
LocaleId fragmentLoc,
LocaleId otherLoc)
Gets the list of all terms of the termbase that exist in a given fragment
for a given source/target pair of locales.
|
| Modifier and Type | Method and Description |
|---|---|
List<TermHit> |
SimpleTBConnector.getExistingStrings(TextFragment fragment,
LocaleId fragmentLocId,
LocaleId otherLocId) |
List<TermHit> |
SimpleTB.getExistingStrings(TextFragment frag,
LocaleId fragmentLoc,
LocaleId otherLoc) |
List<TermHit> |
SimpleTBConnector.getExistingTerms(TextFragment fragment,
LocaleId fragmentLocId,
LocaleId otherLocId) |
List<TermHit> |
SimpleTB.getExistingTerms(TextFragment frag,
LocaleId fragmentLoc,
LocaleId otherLoc) |
| Modifier and Type | Method and Description |
|---|---|
TextFragment |
QueryUtil.createNewFragmentWithCodes(String plainText)
Appends the codes stored apart using
QueryUtil.separateCodesFromText(TextFragment) at the end of a given plain
text. |
TextFragment |
QueryUtil.fromCodedHTMLToFragment(String text,
TextFragment fragment)
Converts an HTML string created with
QueryUtil.toCodedHTML(TextFragment) back into a text fragment,
but with empty inline codes. |
TextFragment |
QueryUtil.fromXLIFF(Element elem,
TextFragment original)
Converts back an XLIFF text contained in a given element into a TextFragment.
|
| Modifier and Type | Method and Description |
|---|---|
int |
TextMatcher.compare(TextFragment frag1,
TextFragment frag2,
int options)
Compare two textFragment content.
|
int |
TextMatcher.compareToBaseTokens(String text1,
List<String> tokens1,
TextFragment frag2)
Compare a list of tokens to a
TextFragment object. |
String |
QueryUtil.fromCodedHTML(String htmlText,
TextFragment fragment,
boolean addMissingCodes)
Converts back a coded HTML to a coded text.
|
String |
QueryUtil.fromCodedHTML(String htmlText,
TextFragment fragment,
boolean addMissingCodes,
boolean removeSpans)
Converts back a coded HTML to a coded text.
|
TextFragment |
QueryUtil.fromCodedHTMLToFragment(String text,
TextFragment fragment)
Converts an HTML string created with
QueryUtil.toCodedHTML(TextFragment) back into a text fragment,
but with empty inline codes. |
TextFragment |
QueryUtil.fromXLIFF(Element elem,
TextFragment original)
Converts back an XLIFF text contained in a given element into a TextFragment.
|
int |
QueryManager.query(TextFragment text)
Queries all enabled translation resources for a given text fragment.
|
String |
QueryUtil.separateCodesFromText(TextFragment frag)
Separate and store codes of a given text fragment.
|
String |
QueryUtil.toCodedHTML(TextFragment fragment)
Converts from coded text to coded HTML.
|
String |
QueryUtil.toXLIFF(TextFragment fragment)
Converts from coded text to XLIFF.
|
| Modifier and Type | Method and Description |
|---|---|
List<List<QueryResult>> |
BaseConnector.batchQuery(List<TextFragment> fragments)
Slow default implementation using query!!
Override to take advantage of servers batch API
|
List<String> |
QueryUtil.toCodedHTML(List<TextFragment> frags)
Converts from coded texts to coded HTML.
|
| Modifier and Type | Method and Description |
|---|---|
int |
SpaceChecker.checkSpaces(TextFragment srcFrag,
TextFragment trgFrag)
Checks and fixes white spaces for a given text fragment.
|
static int |
AbstractChecker.fromFragmentToGeneric(TextFragment frag,
int pos)
Converts a position in a coded-text string
into the same position when the string display uses generic codes.
|
static int |
AbstractChecker.fromOriginalToGeneric(TextFragment frag,
int pos)
Converts a position in a string display using the original code data
into the same position when the string display uses generic codes.
|
static int |
AbstractChecker.fromStrippedToGeneric(TextFragment frag,
int pos)
Converts a position in a string display where codes are stripped
into the same position when the string display uses generic codes.
|
static int |
AbstractChecker.fromStrippedToString(TextFragment frag,
int pos)
Converts a position in a string display where codes are stripped
into the same position when the string display uses original data.
|
protected String |
AbstractChecker.getDisplay(TextFragment frag)
Generates the display string for a source or target text-fragment (e.g.
|
static List<TermHit> |
TermChecker.getExistingTargetStrings(TextFragment frag,
List<TermHit> sourceHits,
boolean betweenCodes) |
static List<TermHit> |
TermChecker.getExistingTargetTerms(TextFragment frag,
List<TermHit> sourceHits)
Get a list of existing target term in a given fragment based on a list of
TermHit object for the source.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
Cleaner.normalizePunctuation(TextFragment srcFrag,
TextFragment trgFrag)
Attempts to make punctuation and spacing around punctuation consistent
according to standard English punctuation rules.
|
| Modifier and Type | Method and Description |
|---|---|
void |
CodesRemover.processFragment(TextFragment tf) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
ExtractionVerificationUtil.compareTextFragments(TextFragment tf1,
TextFragment tf2)
Compares two TextFragments.
|
| Modifier and Type | Method and Description |
|---|---|
void |
InconsistencyCheck.store(String docId,
String subDocId,
String tuId,
String segId,
TextFragment srcTf,
TextFragment trgTf)
Stores the source-target pair for comparison
|
| Modifier and Type | Method and Description |
|---|---|
long |
WordCounter.getWordCount(TextFragment frag) |
| Modifier and Type | Method and Description |
|---|---|
static Tokens |
Tokenizer.tokenize(TextFragment textFragment,
LocaleId language,
String... tokenNames) |
| Modifier and Type | Method and Description |
|---|---|
static long |
WordCounter.count(TextFragment textFragment,
LocaleId language)
Counts words in a given text fragment.
|
| Modifier and Type | Method and Description |
|---|---|
TextFragment |
TranslationUnitVariant.getContent() |
| Modifier and Type | Method and Description |
|---|---|
void |
TranslationUnitVariant.setContent(TextFragment content) |
| Constructor and Description |
|---|
TranslationUnitVariant(LocaleId language,
TextFragment content)
Creates a TUV with the given language and content
|
| Modifier and Type | Method and Description |
|---|---|
List<TmHit> |
PensieveSeeker.searchExact(TextFragment query,
Metadata metadata) |
List<TmHit> |
ITmSeeker.searchExact(TextFragment query,
Metadata metadata)
Get a list of exact matches for a given text fragment, taking inline codes in account.
|
List<TmHit> |
PensieveSeeker.searchFuzzy(TextFragment queryFrag,
int threshold,
int max,
Metadata metadata)
Search for exact and fuzzy matches
|
List<TmHit> |
ITmSeeker.searchFuzzy(TextFragment query,
int threshold,
int maxHits,
Metadata metadata)
Get a list of fuzzy matches for a given text fragment, taking inline codes in account.
|
Copyright © 2022. All rights reserved.