MCPcopy Create free account
hub / github.com/MITK/MITK / AreEqual

Method AreEqual

Modules/SceneSerialization/test/mitkBaseDataCompare.cpp:25–43  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

23#include <usServiceProperties.h>
24
25bool mitk::BaseDataCompare::AreEqual(const BaseData *left, const BaseData *right, ScalarType eps, bool verbose)
26{
27 // Do basic tests that are valid for all types here.
28 // Let specializations only implement a meaningful
29 // comparison of two non-null objects of same type
30 if (left == nullptr && right == nullptr)
31 return true;
32
33 if (AreSameClasses(left, right, verbose))
34 {
35 if (left->GetUID() != right->GetUID())
36 {
37 return false;
38 }
39 return InternalAreEqual(*left, *right, eps, verbose);
40 }
41
42 return false;
43}
44
45bool mitk::BaseDataCompare::AreSameClasses(const BaseData *left, const BaseData *right, bool verbose)
46{

Callers 1

IsDataEqualMethod · 0.80

Calls 1

GetUIDMethod · 0.45

Tested by

no test coverage detected