Medical Imaging Interaction Toolkit  2018.4.99-bd7b41ba
Medical Imaging Interaction Toolkit
mitkArbitraryTimeGeometry.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef ArbitraryTimeGeometry_h
14 #define ArbitraryTimeGeometry_h
15 
16 //MITK
17 #include <mitkTimeGeometry.h>
18 #include <mitkCommon.h>
19 #include <MitkCoreExports.h>
20 
21 namespace mitk
22 {
45  {
46  public:
48 
50  typedef ArbitraryTimeGeometry self;
51  itkFactorylessNewMacro(Self);
52  itkCloneMacro(Self);
53 
62  TimeStepType CountTimeSteps() const override;
69  TimePointType GetMinimumTimePoint() const override;
77  TimePointType GetMaximumTimePoint() const override;
78 
85  TimePointType GetMinimumTimePoint(TimeStepType step) const override;
91  TimePointType GetMaximumTimePoint(TimeStepType step) const override;
92 
97  TimeBounds GetTimeBounds() const override;
98 
102  TimeBounds GetTimeBounds(TimeStepType step) const override;
103 
111  bool IsValidTimePoint(TimePointType timePoint) const override;
119  bool IsValidTimeStep(TimeStepType timeStep) const override;
129  TimePointType TimeStepToTimePoint(TimeStepType timeStep) const override;
143  TimeStepType TimePointToTimeStep(TimePointType timePoint) const override;
150  BaseGeometry::Pointer GetGeometryCloneForTimeStep(TimeStepType timeStep) const override;
151 
161  BaseGeometry::Pointer GetGeometryForTimePoint(TimePointType timePoint) const override;
171  BaseGeometry::Pointer GetGeometryForTimeStep(TimeStepType timeStep) const override;
172 
176  bool IsValid() const override;
177 
181  void Initialize() override;
182 
190  void Expand(TimeStepType size) override;
191 
202  void ReplaceTimeStepGeometries(const BaseGeometry *geometry) override;
203 
210  void SetTimeStepGeometry(BaseGeometry *geometry, TimeStepType timeStep) override;
211 
215  itk::LightObject::Pointer InternalClone() const override;
216 
217  void ClearAllGeometries();
218 
224  void AppendNewTimeStep(BaseGeometry *geometry, TimePointType minimumTimePoint, TimePointType maximumTimePoint);
225 
227  void AppendNewTimeStepClone(const BaseGeometry* geometry,
228  TimePointType minimumTimePoint,
229  TimePointType maximumTimePoint );
230 
231  void ReserveSpaceForGeometries( TimeStepType numberOfGeometries );
232 
233  void PrintSelf(std::ostream &os, itk::Indent indent) const override;
234 
240  bool HasCollapsedFinalTimeStep() const;
241 
242  protected:
243  ~ArbitraryTimeGeometry() override;
244 
245  std::vector<BaseGeometry::Pointer> m_GeometryVector;
246  std::vector<TimePointType> m_MinimumTimePoints;
247  std::vector<TimePointType> m_MaximumTimePoints;
248 
249  }; // end class ArbitraryTimeGeometry
250 
251 } // end namespace MITK
252 #endif // ArbitraryTimeGeometry_h
std::vector< TimePointType > m_MinimumTimePoints
#define MITKCORE_EXPORT
itk::FixedArray< ScalarType, 2 > TimeBounds
Standard typedef for time-bounds.
DataCollection - Class to facilitate loading/accessing structured data.
std::vector< TimePointType > m_MaximumTimePoints
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:40
mitk::ScalarType TimePointType
std::vcl_size_t TimeStepType
std::vector< BaseGeometry::Pointer > m_GeometryVector
BaseGeometry Describes the geometry of a data object.