net.sf.okapi.common.query

## Enum MatchType

- java.lang.Object
- - java.lang.Enum<MatchType>
  - - net.sf.okapi.common.query.MatchType

- All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<MatchType>

      public enum MatchType
      extends java.lang.Enum<MatchType>

  Enumeration of the different match types possible for an alternate translation entry.

  Matches are in ranked order from highest to lowest. Please maintain ranked order when adding new entries.

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `CONCORDANCE` TM concordance or phrase match (usually a word or term only)
    `EXACT` Matches text and codes exactly.
    `EXACT_DOCUMENT_CONTEXT` EXACT and comes from a repeated segment in the same document.
    `EXACT_LOCAL_CONTEXT` EXACT and a small number of segments before and/or after.
    `EXACT_PREVIOUS_VERSION` EXACT and comes from the preceding version of the same document (i.e., if v4 is leveraged this match must come from v3, not v2 or v1!!).
    `EXACT_REPAIRED` Matches text and codes exactly, but only after the result of some automated repair (i.e., number replacement, code repair, capitalization, punctuation etc..)
    `EXACT_STRUCTURAL` EXACT and the structural type of the segment (title, paragraph, list element etc..)
    `EXACT_TEXT_ONLY` Matches text exactly, but there is a difference in one or more codes and/or whitespace
    `EXACT_TEXT_ONLY_PREVIOUS_VERSION` EXACT_TEXT_ONLY and comes from a previous version of the same document
    `EXACT_TEXT_ONLY_UNIQUE_ID` EXACT_TEXT_ONLY and matches with a unique id
    `EXACT_UNIQUE_ID` EXACT and matches a unique id
    `FUZZY` Matches both text and/or codes partially.
    `FUZZY_PREVIOUS_VERSION` FUZZY and comes from a previous version of the same document
    `FUZZY_REPAIRED` Matches both text and/or codes partially and some automated repair (i.e., number replacement, code repair, capitalization, punctuation etc..) was applied to the target
    `FUZZY_UNIQUE_ID` Matches FUZZY with a unique id
    `HUMAN_RECOMMENDED` Improved translation edited by a human.
    `MT` Indicates a translation coming from an MT engine.
    `PHRASE_ASSEMBLED` Matches assembled from phrases in the TM or other resource.
    `UKNOWN` Unknown match type.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static MatchType` | `valueOf(java.lang.String name)` Returns the enum constant of this type with the specified name.
    `static MatchType[]` | `values()` Returns an array containing the constants of this enum type, in the order they are declared.

    - ### Methods inherited from class java.lang.Enum

      `clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Enum Constant Detail

    - #### HUMAN_RECOMMENDED

          public static final MatchType HUMAN_RECOMMENDED

      Improved translation edited by a human.

    - #### EXACT_UNIQUE_ID

          public static final MatchType EXACT_UNIQUE_ID

      EXACT and matches a unique id

    - #### EXACT_PREVIOUS_VERSION

          public static final MatchType EXACT_PREVIOUS_VERSION

      EXACT and comes from the preceding version of the same document (i.e., if v4 is leveraged this match must come from v3, not v2 or v1!!).

    - #### EXACT_LOCAL_CONTEXT

          public static final MatchType EXACT_LOCAL_CONTEXT

      EXACT and a small number of segments before and/or after.

    - #### EXACT_DOCUMENT_CONTEXT

          public static final MatchType EXACT_DOCUMENT_CONTEXT

      EXACT and comes from a repeated segment in the same document.

    - #### EXACT_STRUCTURAL

          public static final MatchType EXACT_STRUCTURAL

      EXACT and the structural type of the segment (title, paragraph, list element etc..)

    - #### EXACT

          public static final MatchType EXACT

      Matches text and codes exactly.

    - #### EXACT_TEXT_ONLY_UNIQUE_ID

          public static final MatchType EXACT_TEXT_ONLY_UNIQUE_ID

      EXACT_TEXT_ONLY and matches with a unique id

    - #### EXACT_TEXT_ONLY_PREVIOUS_VERSION

          public static final MatchType EXACT_TEXT_ONLY_PREVIOUS_VERSION

      EXACT_TEXT_ONLY and comes from a previous version of the same document

    - #### EXACT_TEXT_ONLY

          public static final MatchType EXACT_TEXT_ONLY

      Matches text exactly, but there is a difference in one or more codes and/or whitespace

    - #### EXACT_REPAIRED

          public static final MatchType EXACT_REPAIRED

      Matches text and codes exactly, but only after the result of some automated repair (i.e., number replacement, code repair, capitalization, punctuation etc..)

    - #### FUZZY_UNIQUE_ID

          public static final MatchType FUZZY_UNIQUE_ID

      Matches FUZZY with a unique id

    - #### FUZZY_PREVIOUS_VERSION

          public static final MatchType FUZZY_PREVIOUS_VERSION

      FUZZY and comes from a previous version of the same document

    - #### FUZZY

          public static final MatchType FUZZY

      Matches both text and/or codes partially.

    - #### FUZZY_REPAIRED

          public static final MatchType FUZZY_REPAIRED

      Matches both text and/or codes partially and some automated repair (i.e., number replacement, code repair, capitalization, punctuation etc..) was applied to the target

    - #### PHRASE_ASSEMBLED

          public static final MatchType PHRASE_ASSEMBLED

      Matches assembled from phrases in the TM or other resource.

    - #### MT

          public static final MatchType MT

      Indicates a translation coming from an MT engine.

    - #### CONCORDANCE

          public static final MatchType CONCORDANCE

      TM concordance or phrase match (usually a word or term only)

    - #### UKNOWN

          public static final MatchType UKNOWN

      Unknown match type. Used as default value only - should always be updated to a known match type. A UNKOWN type always sorts below all other matches. Make sure this type is the last in the list.

  - ### Method Detail

    - #### values

          public static MatchType[] values()

      Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:

          for (MatchType c : MatchType.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static MatchType valueOf(java.lang.String name)

      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
        `name` - the name of the enum constant to be returned.
      Returns:
        the enum constant with the specified name
      Throws:
        `java.lang.IllegalArgumentException` - if this enum type has no constant with the specified name
        `java.lang.NullPointerException` - if the argument is null