/** * Returns the upper case equivalent for the specified code point if the * code point is a lower case letter. Otherwise, the specified code point is * returned unchanged. * * @param codePoint * the code point to convert. * @return if {@code codePoint} is a lower case character then its upper * case counterpart, otherwise just {@code codePoint}. */ public static int toUpperCase(int codePoint) { // Optimized case for ASCII if ('a' <= codePoint && codePoint <= 'z') { return (char) (codePoint - ('a' - 'A')); } if (codePoint < 181) { return codePoint; } return toUpperCaseImpl(codePoint); }
/** * Returns the upper case equivalent for the specified code point if the * code point is a lower case letter. Otherwise, the specified code point is * returned unchanged. * * @param codePoint * the code point to convert. * @return if {@code codePoint} is a lower case character then its upper * case counterpart, otherwise just {@code codePoint}. */ public static int toUpperCase(int codePoint) { // Optimized case for ASCII if ('a' <= codePoint && codePoint <= 'z') { return (char) (codePoint - ('a' - 'A')); } if (codePoint < 181) { return codePoint; } return toUpperCaseImpl(codePoint); }
/** * Returns the upper case equivalent for the specified code point if the * code point is a lower case letter. Otherwise, the specified code point is * returned unchanged. * * @param codePoint * the code point to convert. * @return if {@code codePoint} is a lower case character then its upper * case counterpart, otherwise just {@code codePoint}. */ public static int toUpperCase(int codePoint) { // Optimized case for ASCII if ('a' <= codePoint && codePoint <= 'z') { return (char) (codePoint - ('a' - 'A')); } if (codePoint < 181) { return codePoint; } return toUpperCaseImpl(codePoint); }
/** * Returns the upper case equivalent for the specified code point if the * code point is a lower case letter. Otherwise, the specified code point is * returned unchanged. * * @param codePoint * the code point to convert. * @return if {@code codePoint} is a lower case character then its upper * case counterpart, otherwise just {@code codePoint}. */ public static int toUpperCase(int codePoint) { // Optimized case for ASCII if ('a' <= codePoint && codePoint <= 'z') { return (char) (codePoint - ('a' - 'A')); } if (codePoint < 181) { return codePoint; } return toUpperCaseImpl(codePoint); }
/** * Returns the upper case equivalent for the specified code point if the * code point is a lower case letter. Otherwise, the specified code point is * returned unchanged. * * @param codePoint * the code point to convert. * @return if {@code codePoint} is a lower case character then its upper * case counterpart, otherwise just {@code codePoint}. */ public static int toUpperCase(int codePoint) { // Optimized case for ASCII if ('a' <= codePoint && codePoint <= 'z') { return (char) (codePoint - ('a' - 'A')); } if (codePoint < 181) { return codePoint; } return toUpperCaseImpl(codePoint); }
/** * Returns the upper case equivalent for the specified code point if the * code point is a lower case letter. Otherwise, the specified code point is * returned unchanged. * * @param codePoint * the code point to convert. * @return if {@code codePoint} is a lower case character then its upper * case counterpart, otherwise just {@code codePoint}. */ public static int toUpperCase(int codePoint) { // Optimized case for ASCII if ('a' <= codePoint && codePoint <= 'z') { return (char) (codePoint - ('a' - 'A')); } if (codePoint < 181) { return codePoint; } return toUpperCaseImpl(codePoint); }
/** * Returns the upper case equivalent for the specified code point if the * code point is a lower case letter. Otherwise, the specified code point is * returned unchanged. * * @param codePoint * the code point to convert. * @return if {@code codePoint} is a lower case character then its upper * case counterpart, otherwise just {@code codePoint}. */ public static int toUpperCase(int codePoint) { // Optimized case for ASCII if ('a' <= codePoint && codePoint <= 'z') { return (char) (codePoint - ('a' - 'A')); } if (codePoint < 181) { return codePoint; } return toUpperCaseImpl(codePoint); }