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

Function SetIfMissing

Modules/Multilabel/src/mitkDICOMSegmentationPropertyHelper.cpp:41–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

39 }
40
41 void SetIfMissing(mitk::MultiLabelSegmentation* seg,
42 const std::string& key,
43 mitk::BaseProperty* value)
44 {
45 if (seg->GetProperty(key.c_str()).IsNull())
46 seg->SetProperty(key.c_str(), value);
47 }
48
49 // Presence (not non-emptiness) is the check. Type-2 DICOM tags may be
50 // intentionally empty; if Validate insisted on non-empty values, the

Callers 1

CompleteMethod · 0.85

Calls 3

IsNullMethod · 0.45
GetPropertyMethod · 0.45
SetPropertyMethod · 0.45

Tested by

no test coverage detected