com.commercehub.gradle.plugin.avro.MapUtils Maven / Gradle / Ivy
package com.commercehub.gradle.plugin.avro;
import java.util.LinkedHashMap;
import java.util.Map;
public class MapUtils {
/**
* Returns the map of all entries present in the first map but not present in the second map (by key).
*/
static Map asymmetricDifference(Map a, Map b) {
if (b == null || b.isEmpty()) {
return a;
}
Map result = new LinkedHashMap(a);
result.keySet().removeAll(b.keySet());
return result;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy