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

Method AddEnum

Modules/Core/src/DataManagement/mitkEnumerationProperty.cpp:30–42  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28}
29
30bool mitk::EnumerationProperty::AddEnum(const std::string &name, const IdType &id)
31{
32 if (false == this->IsValidEnumerationValue(id) &&
33 false == this->IsValidEnumerationValue(name))
34 {
35 this->GetEnumIds().insert(std::make_pair(id, name));
36 this->GetEnumStrings().insert(std::make_pair(name, id));
37
38 return true;
39 }
40
41 return false;
42}
43
44bool mitk::EnumerationProperty::SetValue(const std::string &name)
45{

Callers 1

Calls 1

Tested by 1