Click or drag to resize
TranslationUnit Methods

The TranslationUnit type exposes the following members.

Methods
  NameDescription
Public methodCheckAndComputeTagAssociations
Computes cross-segment tag associations. Primarily checks or changes the tag-related alignment anchors. Renumbers association anchors.
Public methodComputePlaceables
Computes the list of placeables and their alignment for this translation unit.
Public methodDeleteTags
Deletes all tags from the TU's segments but keeps text placeholders (and locked content tags).
Public methodDeleteTags(SegmentDeleteTagsAction)
Deletes all tags from the TU's segments and performs the specified SegmentDeleteTagsAction on text placeholders and locked content.
Public methodDuplicate
Instantiates and returns a deep copy of the current instance.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetMaxTagAnchor
Returns the highest tag anchor used in any segment, or 0 if no tags are present.
Public methodStatic memberGetSystemFieldType
Returns the field value type for known system and pseudo fields.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodGetType(String)
Retrieves the type of the specified field.
Public methodGetValue(String)
Retrieves the value of a specified field from this translation unit.

The system fields can be retrieved using the following names:

NameCorresponding System Field
chdChange date
chuChange user
usdLast used date
usuLast used user
uscUsage counter
crdCreation date
cruCreation user

Pseudo-fields contain values that are not saved as separate field values, but can be computed from the existing information in a translatin unit. The available pseudo-fields are:

NameCorresponding Pseudo-field
srcSource segment (including tags).
trgTarget segment (including tags)
sourceplainlengthThe length of the plain text in the source segment (without tags)
targetplainlengthThe length of the plain text in the target segment (without tags)
Public methodGetValue(String, FieldValueType)
Retrieves the field value with the specified type from this translation unit.
Public methodIsValid
Determines whether this instance is a valid translation unit.
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodSetValue
Sets the value of the specified field, which can be a system field or a user field. Pseudo fields (such as src, trg, soruceplainlength, etc.) can not be set.

Exceptions will be thrown if the field types are incompatible.

Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodTrim
Trims off peripheral whitespace from the TU's segments.
Public methodValidate
Performs validation checks on this instance. All errors will be reported.
Public methodValidate(SegmentValidationMode)
Performs validation checks on this instance with the specified validation mode.
Top
See Also
Community
Edit

Be the first to Edit the community content of this topic.
Comments