Class OConsts

java.lang.Object
org.omegat.util.OConsts

public final class OConsts extends Object
OmegaT-wide Constants.

// TODO Note: Some constants that are used only in a single class, or are more appropriate in another class (e.g. preference names) are moved in appropriate class definitions.

  • Field Details

    • FILE_PROJECT

      public static final String FILE_PROJECT
      Project Filename
      See Also:
    • PROJ_CUR_VERSION

      public static final String PROJ_CUR_VERSION
      Project Version
      See Also:
    • TMX_EXTENSION

      public static final String TMX_EXTENSION
      See Also:
    • TMX_GZ_EXTENSION

      public static final String TMX_GZ_EXTENSION
      See Also:
    • TMX_ZIP_EXTENSION

      public static final String TMX_ZIP_EXTENSION
      See Also:
    • OMEGAT_TMX

      public static final String OMEGAT_TMX
      See Also:
    • LEVEL1_TMX

      public static final String LEVEL1_TMX
      See Also:
    • LEVEL2_TMX

      public static final String LEVEL2_TMX
      See Also:
    • HELP_HOME

      public static final String HELP_HOME
      See Also:
    • HELP_FIRST_STEPS

      public static final String HELP_FIRST_STEPS
      See Also:
    • HELP_DIR

      public static final String HELP_DIR
      See Also:
    • HELP_FIRST_STEPS_PREFIX

      public static final String HELP_FIRST_STEPS_PREFIX
      See Also:
    • HELP_MANUALS

      public static final String HELP_MANUALS
      See Also:
    • BUILD_DIR

      public static final String BUILD_DIR
      See Also:
    • LICENSE_FILE

      public static final String LICENSE_FILE
      See Also:
    • LAST_CHANGES_FILE

      public static final String LAST_CHANGES_FILE
      See Also:
    • CONTRIBUTORS_FILE

      public static final String CONTRIBUTORS_FILE
      See Also:
    • LIBRARIES_FILE

      public static final String LIBRARIES_FILE
      See Also:
    • FILES_ORDER_FILENAME

      public static final String FILES_ORDER_FILENAME
      See Also:
    • STATUS_EXTENSION

      public static final String STATUS_EXTENSION
      See Also:
    • BACKUP_EXTENSION

      public static final String BACKUP_EXTENSION
      See Also:
    • NEWFILE_EXTENSION

      public static final String NEWFILE_EXTENSION
      See Also:
    • DEFAULT_SOURCE

      public static final String DEFAULT_SOURCE
      Project subfolder for source files default name.
      See Also:
    • DEFAULT_TARGET

      public static final String DEFAULT_TARGET
      Project subfolder for translated files default name.
      See Also:
    • DEFAULT_GLOSSARY

      public static final String DEFAULT_GLOSSARY
      Project subfolder for glossaries default name.
      See Also:
    • DEFAULT_W_GLOSSARY

      public static final String DEFAULT_W_GLOSSARY
      Default name for the project writeable glossary file (inside project)
      See Also:
    • DEFAULT_W_GLOSSARY_SUFF

      public static final String DEFAULT_W_GLOSSARY_SUFF
      Default suffix for project writeable glossary file (outside of project)
      See Also:
    • DEFAULT_TM

      public static final String DEFAULT_TM
      Project subfolder for legacy translation memories default name.
      See Also:
    • DEFAULT_EXPORT_TM

      public static final String DEFAULT_EXPORT_TM
      Project subfolder for exported translation memories.
      See Also:
    • DEFAULT_EXPORT_TM_LEVELS

      public static final String DEFAULT_EXPORT_TM_LEVELS
      Translation memory levels, space-separated lowercase string, to include zero or more of the following values: "omegat", "level1" and/or "level2".
      See Also:
    • AUTO_TM

      public static final String AUTO_TM
      Project subfolder for automatically applied translation memories within the tm folder.
      See Also:
    • AUTO_ENFORCE_TM

      public static final String AUTO_ENFORCE_TM
      Project subfolder for automatically applied translation memories within the tm folder. Existing translation are overwritten
      See Also:
    • MT_TM

      public static final String MT_TM
      Project subfolder for machine translation memories.
      See Also:
    • PENALTY_TM

      public static final String PENALTY_TM
      Project subfolder for generic penalty based translation memories.
      See Also:
    • DEFAULT_OTHERLANG

      public static final String DEFAULT_OTHERLANG
      Project subfolder for translation memories with other languages as alternative sources.
      See Also:
    • DEFAULT_DICT

      public static final String DEFAULT_DICT
      Project subfolder for dictionaries default name.
      See Also:
    • DEFAULT_INTERNAL

      public static final String DEFAULT_INTERNAL
      Project subfolder for project's translation memory.
      See Also:
    • SPELLING_DICT_DIR

      public static final String SPELLING_DICT_DIR
      Default name for spelling dictionary directory
      See Also:
    • EXT_TSV_DEF

      public static final String EXT_TSV_DEF
      Glossary files extensions
      See Also:
    • EXT_TSV_UTF8

      public static final String EXT_TSV_UTF8
      See Also:
    • EXT_TSV_TXT

      public static final String EXT_TSV_TXT
      See Also:
    • EXT_TSV_TSV

      public static final String EXT_TSV_TSV
      See Also:
    • EXT_CSV_UTF8

      public static final String EXT_CSV_UTF8
      See Also:
    • EXT_TBX

      public static final String EXT_TBX
      See Also:
    • STATS_FILENAME

      public static final String STATS_FILENAME
      The name of the file with project statistics: segments, words, chars count. The extension is added with the appropriate output format.
      See Also:
    • STATS_MATCH_FILENAME

      public static final String STATS_MATCH_FILENAME
      The name of the file with project match statistics.
      See Also:
    • STATS_MATCH_PER_FILE_FILENAME

      public static final String STATS_MATCH_PER_FILE_FILENAME
      The name of the file with project match statistics.
      See Also:
    • LAST_ENTRY_NUMBER

      public static final String LAST_ENTRY_NUMBER
      The name of the file with the last entry number for later reopening.
      See Also:
    • IGNORED_WORD_LIST_FILE_NAME

      public static final String IGNORED_WORD_LIST_FILE_NAME
      The name of the file with the ignored words: one ignored word per line
      See Also:
    • LEARNED_WORD_LIST_FILE_NAME

      public static final String LEARNED_WORD_LIST_FILE_NAME
      The name of the file with the correct (learned) words: one word per line
      See Also:
    • SC_AFFIX_EXTENSION

      public static final String SC_AFFIX_EXTENSION
      affix file extension
      See Also:
    • SC_DICTIONARY_EXTENSION

      public static final String SC_DICTIONARY_EXTENSION
      dictionary file extension
      See Also:
    • SC_MORFOLOGIK_EXTENSION

      public static final String SC_MORFOLOGIK_EXTENSION
      morfologik dictionary file extension
      See Also:
    • JAR_EXTENSION

      public static final String JAR_EXTENSION
      jar file extension
      See Also:
    • ZIP_EXTENSION

      public static final String ZIP_EXTENSION
      zip file extension
      See Also:
    • FUZZY_MATCH_THRESHOLD

      public static final int FUZZY_MATCH_THRESHOLD
      The smallest threshold to detect a fuzzy match string
      See Also:
    • ST_MAX_SEARCH_RESULTS

      public static final int ST_MAX_SEARCH_RESULTS
      See Also:
    • XB_COMMENT_SHORTCUT

      public static final String XB_COMMENT_SHORTCUT
      See Also:
    • MAX_NEAR_STRINGS

      public static final int MAX_NEAR_STRINGS
      Number of fuzzy matches to display
      See Also:
    • MAX_BACKUPS

      public static final int MAX_BACKUPS
      See Also:
    • READ_AHEAD_LIMIT

      public static final int READ_AHEAD_LIMIT
      The limit of bytes that various filters may read ahead to inspect files. Increased from 8k (8192 bytes; the default buffer size for BufferedReader) to this number because otherwise EOL detection on .sdlxliff files with large headers can fail.
      See Also:
    • MAX_PARENT_DIRECTORIES_ABS2REL

      public static final int MAX_PARENT_DIRECTORIES_ABS2REL
      The maximum "distance" in parent directories a path can be at when relativizing a path for storage. I.e. how many instances of ../ are in front.

      This is used when storing project folders (source, target, tm, glossary, etc.) located outside of the project root folder.

      This limit is based on the following logic:

      • Users may move their project around locally. This can break relative paths, so absolute paths are desired in this sense.
      • Users may want to share projects via a mechanism that changes the filesystem root (e.g. differing drive letter mapping on Windows). In this case relative paths are desired.
      This limit is a heuristic for determining if a path is "related" to the root: If it's "too far" away then it is assumed to be unrelated, whereas a "nearby" path may be part of a related subtree like ~/Projects.
      See Also:
    • SEGMENT_MARKER_STRING

      public static final String SEGMENT_MARKER_STRING
    • MAX_RECENT_PROJECTS

      public static final int MAX_RECENT_PROJECTS
      Max number of recent projects to remember
      See Also:
    • OMEGAT_WINDOW_WIDTH

      public static final int OMEGAT_WINDOW_WIDTH
      Default window size
      See Also:
    • OMEGAT_WINDOW_HEIGHT

      public static final int OMEGAT_WINDOW_HEIGHT
      See Also: