Skip to content

Instantly share code, notes, and snippets.

@dzwillpower
Created July 17, 2012 14:04
Show Gist options
  • Save dzwillpower/3129556 to your computer and use it in GitHub Desktop.
Save dzwillpower/3129556 to your computer and use it in GitHub Desktop.
把字符串的第一个字母改成大写
private static String getMethodName(String fildeName){
byte[] items = fildeName.getBytes();
items[0] = (byte)((char)items[0]-'a'+'A');;
return new String(items);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment