regex - replace underscore lowercase with uppercase

前端 未结 4 621
误落风尘
误落风尘 2021-01-17 22:36

I\'ve wondering is there a regex pattern that i could use to convert a pattern which is an underscore and a lowercase letter into an uppercase letter. I\'m trying to generat

4条回答
  •  没有蜡笔的小新
    2021-01-17 23:13

    import com.google.common.base.CaseFormat;
    
    protected static String replaceDashesWithCamelCasing(String input){
        return CaseFormat.LOWER_HYPHEN.to(CaseFormat.UPPER_CAMEL, input);
    }
    

提交回复
热议问题