Here you can find the source of toLowercaseFirstLetter(String str)
public static String toLowercaseFirstLetter(String str)
//package com.java2s; //License from project: Open Source License public class Main { public static String toLowercaseFirstLetter(String str) { if (str == null || str.length() == 0) { return str; }// w w w . j ava 2s . co m char firstLetter = str.charAt(0); if (Character.isUpperCase(firstLetter)) { if (str.length() > 1) { return "" + Character.toLowerCase(firstLetter) + str.substring(1); } else { return "" + Character.toLowerCase(firstLetter); } } else { return str; } } }