code: public static String toDecamelize(final String value, final String chr) {
          String camelCasedString = toCamelCase(value);
          String[] words = camelCasedString.split("(?=\\p{Upper})");
          return Arrays.stream(words).map(String::toLowerCase).collect(joining(Optional.ofNullable(chr).orElse(" ")));
      }
docs: Decamelize String
  
  @param value The input String
  @param chr   string to use
  @return String decamelized.