Android examples for java.lang:String Case
to Title Case by locale
import android.text.TextUtils; import java.util.ArrayList; import java.util.Locale; public class Main{ public static String toTitleCase(String s, Locale locale) { if (s.length() <= 1) { return s; }/*from w w w . j av a 2s . c o m*/ return s.toUpperCase(locale).charAt(0) + s.substring(1); } }