Here you can find the source of capitalizeString(String aString)
public static String capitalizeString(String aString)
//package com.java2s; //License from project: LGPL public class Main { public static String capitalizeString(String aString) { if (aString != null && aString.length() > 0) return aString.substring(0, 1).toUpperCase() + aString.substring(1); return ""; }//from w ww . j a v a2 s .co m }