| 403 | |
| 404 | |
| 405 | mitk::modelFit::NodeUIDSetType |
| 406 | mitk::modelFit::GetFitUIDsOfNode(const mitk::DataNode* node, const mitk::DataStorage* storage) |
| 407 | { |
| 408 | auto rule = ModelFitResultRelationRule::New(); |
| 409 | mitk::modelFit::NodeUIDSetType result; |
| 410 | |
| 411 | if (node && storage) |
| 412 | { |
| 413 | auto fitUIDPredicate = mitk::NodePredicateDataProperty::New( |
| 414 | mitk::ModelFitConstants::FIT_UID_PROPERTY_NAME().c_str()); |
| 415 | auto rulePredicate = rule->GetSourcesDetector(node); |
| 416 | auto predicate = NodePredicateAnd::New(fitUIDPredicate, rulePredicate); |
| 417 | mitk::DataStorage::SetOfObjects::ConstPointer nodes = storage->GetSubset(predicate); |
| 418 | |
| 419 | for (mitk::DataStorage::SetOfObjects::ConstIterator pos = nodes->Begin(); pos != nodes->End(); |
| 420 | ++pos) |
| 421 | { |
| 422 | mitk::modelFit::ModelFitInfo::UIDType uid; |
| 423 | pos->Value()->GetData()->GetPropertyList()->GetStringProperty(mitk::ModelFitConstants::FIT_UID_PROPERTY_NAME().c_str(), uid); |
| 424 | |
| 425 | result.insert(uid); |
| 426 | } |
| 427 | |
| 428 | } |
| 429 | |
| 430 | return result; |
| 431 | }; |
nothing calls this directly
no test coverage detected