Class UCaseProps

java.lang.Object
com.ibm.icu.impl.UCaseProps

public final class UCaseProps extends Object
  • Field Details

  • Constructor Details

  • Method Details

    • readData

      private final void readData(ByteBuffer bytes) throws IOException
      Throws:
      IOException
    • addPropertyStarts

      public final void addPropertyStarts(UnicodeSet set)
    • getExceptionsOffset

      private static final int getExceptionsOffset(int props)
    • propsHasException

      static final boolean propsHasException(int props)
    • hasSlot

      private static final boolean hasSlot(int flags, int index)
    • slotOffset

      private static final byte slotOffset(int flags, int index)
    • getSlotValueAndOffset

      private final long getSlotValueAndOffset(int excWord, int index, int excOffset)
    • getSlotValue

      private final int getSlotValue(int excWord, int index, int excOffset)
    • tolower

      public final int tolower(int c)
    • toupper

      public final int toupper(int c)
    • totitle

      public final int totitle(int c)
    • addCaseClosure

      public final void addCaseClosure(int c, UnicodeSet set)
      Adds all simple case mappings and the full case folding for c to sa, and also adds special case closure mappings. c itself is not added. For example, the mappings - for s include long s - for sharp s include ss - for k include the Kelvin sign
    • addSimpleCaseClosure

      public final void addSimpleCaseClosure(int c, UnicodeSet set)
    • strcmpMax

      private final int strcmpMax(String s, int unfoldOffset, int max)
    • addStringCaseClosure

      public final boolean addStringCaseClosure(String s, UnicodeSet set)
      Maps the string to single code points and adds the associated case closure mappings. The string is mapped to code points if it is their full case folding string. In other words, this performs a reverse full case folding and then adds the case closure items of the resulting code points. If the string is found and its closure applied, then the string itself is added as well as part of its code points' closure.
      Returns:
      true if the string was found
    • getType

      public final int getType(int c)
      Returns:
      NONE, LOWER, UPPER, TITLE
    • getTypeOrIgnorable

      public final int getTypeOrIgnorable(int c)
      Returns:
      like getType() but also sets IGNORABLE if c is case-ignorable
    • getDotType

      public final int getDotType(int c)
      Returns:
      NO_DOT, SOFT_DOTTED, ABOVE, OTHER_ACCENT
    • isSoftDotted

      public final boolean isSoftDotted(int c)
    • isCaseSensitive

      public final boolean isCaseSensitive(int c)
    • getCaseLocale

      public static final int getCaseLocale(Locale locale)
    • getCaseLocale

      public static final int getCaseLocale(ULocale locale)
    • getCaseLocale

      private static final int getCaseLocale(String language)
      Accepts both 2- and 3-letter language subtags.
    • isFollowedByCasedLetter

      private final boolean isFollowedByCasedLetter(UCaseProps.ContextIterator iter, int dir)
    • isPrecededBySoftDotted

      private final boolean isPrecededBySoftDotted(UCaseProps.ContextIterator iter)
    • isPrecededBy_I

      private final boolean isPrecededBy_I(UCaseProps.ContextIterator iter)
    • isFollowedByMoreAbove

      private final boolean isFollowedByMoreAbove(UCaseProps.ContextIterator iter)
    • isFollowedByDotAbove

      private final boolean isFollowedByDotAbove(UCaseProps.ContextIterator iter)
    • toFullLower

      public final int toFullLower(int c, UCaseProps.ContextIterator iter, Appendable out, int caseLocale)
      Get the full lowercase mapping for c.
      Parameters:
      c - Character to be mapped.
      iter - Character iterator, used for context-sensitive mappings. See ContextIterator for details. If iter==null then a context-independent result is returned.
      out - If the mapping result is a string, then it is appended to out.
      caseLocale - Case locale value from ucase_getCaseLocale().
      Returns:
      Output code point or string length, see MAX_STRING_LENGTH.
      See Also:
    • toUpperOrTitle

      private final int toUpperOrTitle(int c, UCaseProps.ContextIterator iter, Appendable out, int loc, boolean upperNotTitle)
    • toFullUpper

      public final int toFullUpper(int c, UCaseProps.ContextIterator iter, Appendable out, int caseLocale)
    • toFullTitle

      public final int toFullTitle(int c, UCaseProps.ContextIterator iter, Appendable out, int caseLocale)
    • fold

      public final int fold(int c, int options)
    • toFullFolding

      public final int toFullFolding(int c, Appendable out, int options)
    • hasBinaryProperty

      public final boolean hasBinaryProperty(int c, int which)
    • getTrie

      static Trie2_16 getTrie()
    • getTypeFromProps

      static final int getTypeFromProps(int props)
      Returns:
      NONE, LOWER, UPPER, TITLE
    • getTypeAndIgnorableFromProps

      private static final int getTypeAndIgnorableFromProps(int props)
      Returns:
      like getTypeFromProps() but also sets IGNORABLE if props indicate case-ignorable
    • isUpperOrTitleFromProps

      static final boolean isUpperOrTitleFromProps(int props)
    • getDelta

      static final int getDelta(int props)