<p>firstUpperCase.</p>

@param s a {@link java.lang.String} object.
@return a {@link java.lang.String} object.
431861
public static String firstUpperCase(String s) {
		String first = s.length() > 0 ? s.substring(0, 1).toUpperCase() : "";
		String second = s.length() > 1 ? s.substring(1).toLowerCase() : "";
		return first + second;
	}
1071050
public static String capitalize (String s)
    {
        if (isBlank(s)) {
            return s;
        }
        char c = s.charAt(0);
        if (Character.isUpperCase(c)) {
            return s;
        } else {
            return String.valueOf(Character.toUpperCase(c)) + s.substring(1);
        }
    }
100211
public static <T extends CharSequence> T validateUpperCase(T value, String errorMsg) throws ValidateException {
		if (false == isUpperCase(value)) {
			throw new ValidateException(errorMsg);
		}
		return value;
	}
596340
public static String initials(final String str, final String charsetName) throws UnsupportedEncodingException {
		return initials(new String(str.getBytes(charsetName), "UTF-8"));
	}
593550
public T getValue(final String name) {
		if (name == null) {
			return null;
		}
		String uppercased = name.toUpperCase();
		return namesToValues.get(uppercased);
	}
691218
public static String capitalize(String s) {
		if (s == null || isEmpty(s)) {
			return s;
		}
		return (new StringBuilder(s.length())).append(Character.toTitleCase(s.charAt(0))).append(s.substring(1)).toString();
	}
566084
public static String toLowerString(String s) {
        int len = s.length();
        int idx = 0;
        for (; idx < len; idx++) {
            if (isUpper(s.charAt(idx))) {
                break;
            }
        }
        if (idx == len) {
            return s;
        }

        char[] buf = new char[len];
        for (int i = 0; i < len; i++) {
            char c = s.charAt(i);
            buf[i] = (i < idx) ? c : toLower(c);
        }
        return new String(buf);
    }
182418
static String capitalizeFirstWordAsciiOnly(String s) {
    if (s == null || s.isEmpty()) {
      return s;
    }
    int secondWordStart = s.length();
    for (int i = 1; i < s.length(); i++) {
      if (!isLowerCaseAsciiOnly(s.charAt(i))) {
        secondWordStart = i;
        break;
      }
    }
    return toUpperCaseAsciiOnly(s.substring(0, secondWordStart)) + s.substring(secondWordStart);
  }
566334
private static final String trimFirstWord(String s) {
        s = s.trim();
        char[] chars = s.toCharArray();
        int firstSpace = -1;

        for (int i = 0; i < chars.length; i++) {
            char c = chars[i];
            if (Character.isWhitespace(c)) {
                firstSpace = i;
                break;
            }
        }

        if (firstSpace == -1) {
            return s;
        }

        s = s.substring(firstSpace).trim();
        s = capitalize(s);

        return s;
    }
992019
protected String escape(String s) {
		if(s == null)
			return null;
        StringBuilder sb = new StringBuilder();
        escape(s, sb);
        return sb.toString();
    }
1188298
public static String lowerCaseFirstChar(String s) {
        if (s.isEmpty()) {
            return s;
        }

        char first = s.charAt(0);
        if (isLowerCase(first)) {
            return s;
        }

        return toLowerCase(first) + s.substring(1);
    }
1041508
public static String capitalize(String s) {
		if (Character.isLowerCase(s.charAt(0))) {
			return Character.toUpperCase(s.charAt(0)) + s.substring(1);
		} else {
			return s;
		}
	}
346668
String upcaseFirst(String name)
   {
      StringBuilder sb = new StringBuilder();
      sb.append(name.substring(0, 1).toUpperCase(Locale.ENGLISH));
      sb.append(name.substring(1));
      return sb.toString();
   }
1009449
public static String capitalizeWord( String s )
	{
		// validate
		if( (s == null) || (s.length() == 0) )
		{
			return s;
		}
		return s.substring(0, 1).toUpperCase() + s.substring(1).toLowerCase();
	}
780295
public static String capitalizePropertyName(String s) {
		if (s.length() == 0) {
			return s;
		}

		char[] chars = s.toCharArray();
		chars[0] = Character.toUpperCase(chars[0]);
		return new String(chars);
	}
1050816
private static String lcFirst(String s)
    {
        if (s == null || s.isEmpty())
        {
            return s;
        }

        return Character.toLowerCase(s.charAt(0))
                + (s.length() == 1 ? "" : s.substring(1));
    }
1324810
public AsciiString toUpperCase() {
        boolean uppercased = true;
        int i, j;
        final int len = length() + arrayOffset();
        for (i = arrayOffset(); i < len; ++i) {
            byte b = value[i];
            if (b >= 'a' && b <= 'z') {
                uppercased = false;
                break;
            }
        }

        // Check if this string does not contain any lowercase characters.
        if (uppercased) {
            return this;
        }

        final byte[] newValue = PlatformDependent.allocateUninitializedArray(length());
        for (i = 0, j = arrayOffset(); i < newValue.length; ++i, ++j) {
            newValue[i] = toUpperCase(value[j]);
        }

        return new AsciiString(newValue, false);
    }