Here you can find the source of toJavaName(String name)
public static String toJavaName(String name)
//package com.java2s; //License from project: Open Source License public class Main { public static String toJavaName(String name) { if (name != null && !"".equals(name)) { String rs = ""; name = name.toLowerCase();//from ww w . j av a2 s . co m String[] names = name.split("_"); for (String string : names) { rs += string.substring(0, 1).toUpperCase() + string.substring(1, string.length()); } return rs; } return name; } }