Manages level/window presets loaded from an XML file.
More...
#include <mitkLevelWindowPreset.h>
Manages level/window presets loaded from an XML file.
Reads named level/window presets from an XML resource file (mitkLevelWindowPresets.xml) and provides access to the stored values.
Definition at line 29 of file mitkLevelWindowPreset.h.
◆ LevelWindowPreset()
| mitk::LevelWindowPreset::LevelWindowPreset |
( |
| ) |
|
|
protected |
◆ ~LevelWindowPreset()
| mitk::LevelWindowPreset::~LevelWindowPreset |
( |
| ) |
|
|
overrideprotected |
◆ getLevel()
| double mitk::LevelWindowPreset::getLevel |
( |
std::string |
name | ) |
|
Get the level value for a named preset.
- Parameters
-
| name | The name of the preset. |
- Returns
- The level value associated with the name.
◆ getLevelPresets()
| std::map<std::string, double>& mitk::LevelWindowPreset::getLevelPresets |
( |
| ) |
|
Get a reference to the map of all level presets.
- Returns
- Map from preset name to level value.
◆ getWindow()
| double mitk::LevelWindowPreset::getWindow |
( |
std::string |
window | ) |
|
Get the window value for a named preset.
- Parameters
-
| window | The name of the preset. |
- Returns
- The window value associated with the name.
◆ getWindowPresets()
| std::map<std::string, double>& mitk::LevelWindowPreset::getWindowPresets |
( |
| ) |
|
Get a reference to the map of all window presets.
- Returns
- Map from preset name to window value.
◆ LoadPreset() [1/2]
| bool mitk::LevelWindowPreset::LoadPreset |
( |
| ) |
|
Load presets from the default module resource file.
- Returns
- True if parsing was successful.
◆ LoadPreset() [2/2]
| bool mitk::LevelWindowPreset::LoadPreset |
( |
std::string |
fileName | ) |
|
Load presets from a specified XML file.
- Parameters
-
| fileName | Path to the XML file to load. |
- Returns
- True if parsing was successful.
◆ New()
◆ newPresets()
| void mitk::LevelWindowPreset::newPresets |
( |
std::map< std::string, double > |
newLevel, |
|
|
std::map< std::string, double > |
newWindow |
|
) |
| |
Replace all presets with new level and window maps and save.
- Parameters
-
| newLevel | New map of level presets. |
| newWindow | New map of window presets. |
◆ vtkTypeMacro()
The documentation for this class was generated from the following file: