Package org.sosy_lab.common.collect
Class MapsDifference
java.lang.Object
org.sosy_lab.common.collect.MapsDifference
Utilities for handling differences between maps.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classDefault implementation ofMapsDifference.Visitorwith empty methods.static final recordClass representing the difference between two maps for a given key.static interfaceInterface for visiting map entries differing between two maps. -
Method Summary
Modifier and TypeMethodDescriptionstatic <K,V> MapsDifference.Visitor<K, V> collectMapsDifferenceTo(Collection<MapsDifference.Entry<K, V>> target) Returns aMapsDifference.Visitorthat collects all map differences asMapsDifference.Entryobjects into a given collection.static <K,V> MapsDifference.Visitor<K, V> Returns a defaultMapsDifference.Visitorthat does nothing.
-
Method Details
-
ignoreMapsDifference
Returns a defaultMapsDifference.Visitorthat does nothing. Use this if a method requires a visitor to be passed but you are not interested in the elements. -
collectMapsDifferenceTo
public static <K,V> MapsDifference.Visitor<K,V> collectMapsDifferenceTo(Collection<MapsDifference.Entry<K, V>> target) Returns aMapsDifference.Visitorthat collects all map differences asMapsDifference.Entryobjects into a given collection.
-