public void addOrReplace(Object[][] pairs) { for (Object[] pair : pairs) if (pair.length == 2) addOrReplace((K) pair[0], (V) pair[1]); }