Class EMFCompareUtils.EqualityHelper

  • All Implemented Interfaces:
    Serializable, Cloneable, Map<org.eclipse.emf.ecore.EObject,​org.eclipse.emf.ecore.EObject>
    Enclosing class:
    EMFCompareUtils

    public static class EMFCompareUtils.EqualityHelper
    extends HashMap<org.eclipse.emf.ecore.EObject,​org.eclipse.emf.ecore.EObject>
    See Also:
    Serialized Form
    • Constructor Detail

      • EqualityHelper

        public EqualityHelper()
    • Method Detail

      • equals

        public EMFCompareUtils.Diff equals​(org.eclipse.emf.ecore.EObject eObject1,
                                           org.eclipse.emf.ecore.EObject eObject2)
        Returns whether eObject1 and eObject2 are equal in the context of this helper instance.
        Returns:
        whether eObject1 and eObject2 are equal.
        Since:
        2.1.0
      • equals

        public EMFCompareUtils.Diff equals​(List<org.eclipse.emf.ecore.EObject> list1,
                                           List<org.eclipse.emf.ecore.EObject> list2,
                                           org.eclipse.emf.ecore.EStructuralFeature feature)
        Returns whether list1 and list2 contain equal EObjects at the same index. It is assumed that list1 and list2 only contain EObjects.
        Returns:
        whether list1 and list2 contain equal objects.
        Since:
        2.1.0
      • haveEqualFeature

        protected EMFCompareUtils.Diff haveEqualFeature​(org.eclipse.emf.ecore.EObject eObject1,
                                                        org.eclipse.emf.ecore.EObject eObject2,
                                                        org.eclipse.emf.ecore.EStructuralFeature feature)
        Returns whether the two objects have equal isSet states and values for the feature.
        Returns:
        whether the two objects have equal isSet states and values for the feature.
        Since:
        2.2.0
        See Also:
        equals(EObject, EObject), #equals(List, List)
      • haveEqualReference

        protected EMFCompareUtils.Diff haveEqualReference​(org.eclipse.emf.ecore.EObject eObject1,
                                                          org.eclipse.emf.ecore.EObject eObject2,
                                                          org.eclipse.emf.ecore.EReference reference)
        Returns whether the two objects have equal values for the reference.
        Returns:
        whether the two objects have equal values for the reference.
        Since:
        2.1.0
        See Also:
        equals(EObject, EObject), #equals(List, List)
      • haveEqualAttribute

        protected EMFCompareUtils.Diff haveEqualAttribute​(org.eclipse.emf.ecore.EObject eObject1,
                                                          org.eclipse.emf.ecore.EObject eObject2,
                                                          org.eclipse.emf.ecore.EAttribute attribute)
        Returns whether the two objects have equal values for the attribute.
        Returns:
        whether the two objects have equal values for the attribute.
        Since:
        2.1.0
        See Also:
        #equalFeatureMaps(FeatureMap, FeatureMap)
      • equalFeatureMaps

        protected EMFCompareUtils.Diff equalFeatureMaps​(org.eclipse.emf.ecore.util.FeatureMap featureMap1,
                                                        org.eclipse.emf.ecore.util.FeatureMap featureMap2,
                                                        org.eclipse.emf.ecore.EAttribute attribute)
        Returns whether the two feature maps are equal .
        Returns:
        whether the two feature maps are equal.
        Since:
        2.1.0
      • equalFeatureMapValues

        protected EMFCompareUtils.Diff equalFeatureMapValues​(Object value1,
                                                             Object value2,
                                                             org.eclipse.emf.ecore.EStructuralFeature feature)
        Returns whether the two values of a feature map are equal.
        Returns:
        whether the two values of a feature map are equal.
        Since:
        2.2.0