@Test public void testCamelToUnderscore() { String input = "myCamelCaseTest"; String expected = "my_camel_case_test"; String actual = Strings.camelToUnderscore(input); assertEquals(expected, actual); }
public static String camelToUnderscore(final String input) { String result = input; if (input instanceof String) { result = input.replaceAll("([a-z])([A-Z])", "$1_$2").toLowerCase(); } return result; }
Strings { public static String camelToUnderscore(final String input) { String result = input; if (input instanceof String) { result = input.replaceAll("([a-z])([A-Z])", "$1_$2").toLowerCase(); } return result; } }
Strings { public static String camelToUnderscore(final String input) { String result = input; if (input instanceof String) { result = input.replaceAll("([a-z])([A-Z])", "$1_$2").toLowerCase(); } return result; }  }
Strings { public static String camelToUnderscore(final String input) { String result = input; if (input instanceof String) { result = input.replaceAll("([a-z])([A-Z])", "$1_$2").toLowerCase(); } return result; }  static String camelToUnderscore(final String input); static String join(final String delim, final String... strings); static String canonicalize(final String name); }
Strings { public static String camelToUnderscore(final String input) { String result = input; if (input instanceof String) { result = input.replaceAll("([a-z])([A-Z])", "$1_$2").toLowerCase(); } return result; }  static String camelToUnderscore(final String input); static String join(final String delim, final String... strings); static String canonicalize(final String name);  }