Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkIntPropertyExtension.cpp
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
18 
19 namespace mitk
20 {
21  struct IntPropertyExtension::Impl
22  {
23  Impl();
24  Impl(int minimum, int maximum, int singleStep);
25  ~Impl();
26 
27  int Maximum;
28  int Minimum;
29  int SingleStep;
30  };
31 
32  IntPropertyExtension::Impl::Impl() : Maximum(100), Minimum(0), SingleStep(1) {}
33  IntPropertyExtension::Impl::Impl(int minimum, int maximum, int singleStep)
34  : Maximum(maximum), Minimum(minimum), SingleStep(singleStep)
35  {
36  }
37 
38  IntPropertyExtension::Impl::~Impl() {}
39 }
40 
41 mitk::IntPropertyExtension::IntPropertyExtension() : m_Impl(new Impl)
42 {
43 }
44 
45 mitk::IntPropertyExtension::IntPropertyExtension(int minimum, int maximum, int singleStep)
46  : m_Impl(new Impl(minimum, maximum, singleStep))
47 {
48 }
49 
50 mitk::IntPropertyExtension::~IntPropertyExtension()
51 {
52  delete m_Impl;
53 }
54 
56 {
57  return m_Impl->Maximum;
58 }
59 
61 {
62  m_Impl->Maximum = maximum;
63 }
64 
66 {
67  return m_Impl->Minimum;
68 }
69 
71 {
72  m_Impl->Minimum = minimum;
73 }
74 
76 {
77  return m_Impl->SingleStep;
78 }
79 
81 {
82  m_Impl->SingleStep = singleStep;
83 }
DataCollection - Class to facilitate loading/accessing structured data.