| Trees | Indices | Help | 
 | 
|---|
|  | 
object --+
         |
        TranslationUnit
Base class for translation units.
Our concept of a translation unit is influenced heavily by XLIFF: http://www.oasis-open.org/committees/xliff/documents/xliff-specification.htm
As such most of the method- and variable names borrows from XLIFF terminology.
A translation unit consists of the following:
| 
 | |||
| 
 | |||
| Boolean | 
 | ||
| string | 
 | ||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| 
 | |||
| Inherited from  | |||
| Target | |||
|---|---|---|---|
| 
 | |||
| Integer | 
 | ||
| Notes | |||
| 
 | |||
| 
 | |||
| 
 | |||
| Locations | |||
| List | 
 | ||
| 
 | |||
| 
 | |||
| Errors | |||
| 
 | |||
| Dictionary | 
 | ||
| 
 | |||
| 
 | |||
| 
 | |||
| Inherited from  | |||
| 
 | |||
| 
 Constructs a TranslationUnit containing the given source string. 
 | 
| 
 Compares two TranslationUnits. 
 | 
| 
 Returns the length of the target string. 
 Note: Plural forms might be combined. | 
| 
 A unique identifier for this unit. 
 | 
| 
 A list of source code locations. 
 Note: Shouldn't be implemented if the format doesn't support it. | 
| 
 Add one location to the list of locations. Note: Shouldn't be implemented if the format doesn't support it. | 
| 
 Add a location or a list of locations. Note: Most classes shouldn't need to implement this, but should rather implement addlocation(). Warning: This method might be removed in future. | 
| 
 Returns all notes about this unit. It will probably be freeform text or something reasonable that can be synthesised by the format. It should not include location comments (see getlocations()). | 
| 
 Adds a note (comment). 
 | 
| 
 Adds an error message to this unit. 
 | 
| 
 Marks the unit to indicate whether it needs review. 
 | 
| 
 Indicates whether this unit is translated. This should be used rather than deducing it from .target, to ensure that other classes can implement more functionality (as XLIFF does). | 
| 
 Indicates whether this unit can be translated. This should be used to distinguish real units for translation from header, obsolete, binary or other blank units. | 
| 
 Used to see if this unit has no source or target string. Note: This is probably used more to find translatable units, and we might want to move in that direction rather and get rid of this. | 
| Trees | Indices | Help | 
 | 
|---|
| Generated by Epydoc 3.0.1 on Wed Mar 26 12:49:29 2008 | http://epydoc.sourceforge.net |