test_class.file: kilt-core/src/test/java/de/poiu/kilt/facade/creation/BundleNormalizerTest.java
test_class.identifier: BundleNormalizerTest
test_case.body: @Test
    public void testToClassName_startsWithNumber() {
      final String input = "1st of a series";
      final String expected= "_1stOfASeries";
  
      final String actual= BundleNormalizer.toClassName(input);
  
      assertThat(actual).isEqualTo(expected);
    }
test_case.class_method_signature: BundleNormalizerTest.testToClassName_startsWithNumber()
test_case.full_signature: @Test public void testToClassName_startsWithNumber()
test_case.identifier: testToClassName_startsWithNumber
test_case.invocations: toClassName isEqualTo assertThat
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testToClassName_startsWithNumber()
focal_class.declarator: LOGGER= Logger.getLogger(BundleNormalizer.class.getName())
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOGGER= Logger.getLogger(BundleNormalizer.class.getName());
focal_class.type: Logger
focal_class.var_name: LOGGER
focal_class.declarator: UMLAUT_REPLACEMENTS= ImmutableMap.<String, String>builder()
            .put("ä", "ae")
            .put("Ä", "AE")
            .put("ö", "oe")
            .put("Ö", "OE")
            .put("ü", "ue")
            .put("Ü", "UE")
            .put("ß", "ss")
            .put("ẞ", "SS")
            .put("Æ", "AE")
            .put("Œ", "OE")
            .build()
focal_class.modifier: private static final
focal_class.original_string: private static final Map<String, String> UMLAUT_REPLACEMENTS= ImmutableMap.<String, String>builder()
            .put("ä", "ae")
            .put("Ä", "AE")
            .put("ö", "oe")
            .put("Ö", "OE")
            .put("ü", "ue")
            .put("Ü", "UE")
            .put("ß", "ss")
            .put("ẞ", "SS")
            .put("Æ", "AE")
            .put("Œ", "OE")
            .build();
focal_class.type: Map<String, String>
focal_class.var_name: UMLAUT_REPLACEMENTS
focal_class.file: kilt-core/src/main/java/de/poiu/kilt/facade/creation/BundleNormalizer.java
focal_class.identifier: BundleNormalizer
focal_class.class_method_signature: BundleNormalizer.toClassName(String s)
focal_class.full_signature: public static String toClassName(String s)
focal_class.identifier: toClassName
focal_class.modifiers: public static
focal_class.parameters: (String s)
focal_class.return: String
focal_class.signature: String toClassName(String s)
focal_class.class_method_signature: BundleNormalizer.toFieldName(String s)
focal_class.full_signature: public static String toFieldName(String s)
focal_class.identifier: toFieldName
focal_class.modifiers: public static
focal_class.parameters: (String s)
focal_class.return: String
focal_class.signature: String toFieldName(String s)
focal_class.class_method_signature: BundleNormalizer.toConstName(String s)
focal_class.full_signature: public static String toConstName(String s)
focal_class.identifier: toConstName
focal_class.modifiers: public static
focal_class.parameters: (String s)
focal_class.return: String
focal_class.signature: String toConstName(String s)
focal_class.class_method_signature: BundleNormalizer.toBundleName(String s)
focal_class.full_signature: public static String toBundleName(String s)
focal_class.identifier: toBundleName
focal_class.modifiers: public static
focal_class.parameters: (String s)
focal_class.return: String
focal_class.signature: String toBundleName(String s)
focal_class.class_method_signature: BundleNormalizer.normalize(String s)
focal_class.full_signature: protected static String normalize(String s)
focal_class.identifier: normalize
focal_class.modifiers: protected static
focal_class.parameters: (String s)
focal_class.return: String
focal_class.signature: String normalize(String s)
focal_class.class_method_signature: BundleNormalizer.replaceUmlauts(final String s)
focal_class.full_signature: protected static String replaceUmlauts(final String s)
focal_class.identifier: replaceUmlauts
focal_class.modifiers: protected static
focal_class.parameters: (final String s)
focal_class.return: String
focal_class.signature: String replaceUmlauts(final String s)
focal_method.body: public static String toClassName(String s) {
      Require.nonNull(s, "parameter s may not be null or empty.");
      Require.nonWhitespace(s, "parameter s may not be null or empty.");
  
      s= normalize(s);
  
      final char[] chars= s.toCharArray();
      final StringBuilder sb= new StringBuilder();
  
      //if the first char is a number, prepend it by an underscore
      if (Character.isDigit(chars[0])) {
        sb.append("_");
      }
  
      //always uppercase the first char
      sb.append(Character.toUpperCase(chars[0]));
  
      for (int i=1; i<chars.length; i++) {
        if (chars[i] == '_') {
          // if char is underscore, leave it out…
          if (chars.length > i+1) {
            // … and uppercase next letter, if available
            final char nextChar= chars[i+1];
            sb.append(Character.toUpperCase(nextChar));
            i++;
          }
        } else {
          // leave all other chars as the are
          sb.append(chars[i]);
        }
      }
  
      return sb.toString();
    }
focal_method.class_method_signature: BundleNormalizer.toClassName(String s)
focal_method.full_signature: public static String toClassName(String s)
focal_method.identifier: toClassName
focal_method.invocations: nonNull nonWhitespace normalize toCharArray isDigit append append toUpperCase append toUpperCase append toString
focal_method.modifiers: public static
focal_method.parameters: (String s)
focal_method.return: String
focal_method.signature: String toClassName(String s)