Logo Search packages:      
Sourcecode: icu version File versions  Download package

Enum for the kinds of checks that USpoofChecker can perform. These enum values are used both to select the set of checks that will be performed, and to report results from the check function.

ICU 4.2

Enumerator:
USPOOF_SINGLE_SCRIPT_CONFUSABLE  Single script confusable test. When testing whether two identifiers are confusable, report that they are if both are from the same script and they are visually confusable. Note: this test is not applicable to a check of a single identifier.
USPOOF_MIXED_SCRIPT_CONFUSABLE  Mixed script confusable test. When checking a single identifier, report a problem if the identifier contains multiple scripts, and is confusable with some other identifier in a single script When testing whether two identifiers are confusable, report that they are if the two IDs are visually confusable, and at least one contains characters from more than one script.
USPOOF_WHOLE_SCRIPT_CONFUSABLE  Whole script confusable test. When checking a single identifier, report a problem if The identifier is of a single script, and there exists a confusable identifier in another script. When testing whether two identifiers are confusable, report that they are if each is of a single script, the scripts of the two identifiers are different, and the identifiers are visually confusable.
USPOOF_ANY_CASE  Any Case Modifier for confusable identifier tests. If specified, consider all characters, of any case, when looking for confusables. If USPOOF_ANY_CASE is not specified, identifiers being checked are assumed to have been case folded. Upper case confusable characters will not be checked. Selects between Lower Case Confusable and Any Case Confusable.
USPOOF_SINGLE_SCRIPT  Check that an identifier contains only characters from a single script (plus chars from the common and inherited scripts.) Applies to checks of a single identifier check only.
USPOOF_INVISIBLE  Check an identifier for the presence of invisible characters, such as zero-width spaces, or character sequences that are likely not to display, such as multiple occurrences of the same non-spacing mark. This check does not test the input string as a whole for conformance to any particular syntax for identifiers.
USPOOF_CHAR_LIMIT  Check that an identifier contains only characters from a specified set of acceptable characters. See uspoof_setAllowedChars() and uspoof_setAllowedLocales().

Definition at line 161 of file uspoof.h.

                          {
    /**   Single script confusable test.
      *   When testing whether two identifiers are confusable, report that they are if
      *   both are from the same script and they are visually confusable.
      *   Note: this test is not applicable to a check of a single identifier.
      */
    USPOOF_SINGLE_SCRIPT_CONFUSABLE =   1,

    /** Mixed script confusable test.
     *  When checking a single identifier, report a problem if
     *    the identifier contains multiple scripts, and
     *    is confusable with some other identifier in a single script
     *  When testing whether two identifiers are confusable, report that they are if
     *    the two IDs are visually confusable, 
     *    and at least one contains characters from more than one script.
     */
    USPOOF_MIXED_SCRIPT_CONFUSABLE  =   2,

    /** Whole script confusable test.
     *  When checking a single identifier, report a problem if
     *    The identifier is of a single script, and
     *    there exists a confusable identifier in another script.
     *  When testing whether two identifiers are confusable, report that they are if
     *    each is of a single script, 
     *    the scripts of the two identifiers are different, and
     *    the identifiers are visually confusable.
     */
    USPOOF_WHOLE_SCRIPT_CONFUSABLE  =   4,
    
    /** Any Case Modifier for confusable identifier tests.
        If specified, consider all characters, of any case, when looking for confusables.
        If USPOOF_ANY_CASE is not specified, identifiers being checked are assumed to have been
        case folded.  Upper case confusable characters will not be checked.
        Selects between Lower Case Confusable and
        Any Case Confusable.   */
    USPOOF_ANY_CASE                 =   8,

    /** Check that an identifier contains only characters from a
      * single script (plus chars from the common and inherited scripts.)
      * Applies to checks of a single identifier check only.
      */
    USPOOF_SINGLE_SCRIPT            =  16,
    
    /** Check an identifier for the presence of invisible characters,
      * such as zero-width spaces, or character sequences that are
      * likely not to display, such as multiple occurrences of the same
      * non-spacing mark.  This check does not test the input string as a whole
      * for conformance to any particular syntax for identifiers.
      */
    USPOOF_INVISIBLE                =  32,

    /** Check that an identifier contains only characters from a specified set
      * of acceptable characters.  See uspoof_setAllowedChars() and
      * uspoof_setAllowedLocales().
      */
    USPOOF_CHAR_LIMIT               =  64,

    USPOOF_ALL_CHECKS               = 0x7f
    } USpoofChecks;


Generated by  Doxygen 1.6.0   Back to index