HHH-13549 StringHelper: Prefer generics over casting

This commit is contained in:
Sanne Grinovero 2019-08-07 22:07:13 +01:00
parent 0bf9bb1423
commit de8d6d095f
1 changed files with 2 additions and 2 deletions

View File

@ -399,10 +399,10 @@ public final class StringHelper {
return buf.append( array[len - 1] ).toString();
}
public static String[] multiply(String string, Iterator placeholders, Iterator replacements) {
public static String[] multiply(String string, Iterator<String> placeholders, Iterator<String[]> replacements) {
String[] result = new String[] {string};
while ( placeholders.hasNext() ) {
result = multiply( result, (String) placeholders.next(), (String[]) replacements.next() );
result = multiply( result, placeholders.next(), replacements.next() );
}
return result;
}