KWStyle - itkVersion.h
 
Matrix View
Description

1 /*=========================================================================
2
3   Program:   Insight Segmentation & Registration Toolkit
4   Module:    $RCSfile: itkVersion.h.html,v $
5   Language:  C++
6   Date:      $Date: 2006/01/17 19:15:49 $
7   Version:   $Revision: 1.4 $
8
9   Copyright (c) Insight Software Consortium. All rights reserved.
10   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
11
12   Portions of this code are covered under the VTK copyright.
13   See VTKCopyright.txt or http://www.kitware.com/VTKCopyright.htm for details.
14
15      This software is distributed WITHOUT ANY WARRANTY; without even 
16      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
17 IND *****PURPOSE.  See the above copyright notices for more information.
18
19 =========================================================================*/
20 #ifndef __itkVersion_h
21 #define __itkVersion_h
22
23 #include "itkObject.h"
24 #include "itkObjectFactory.h"
25
26 #define ITK_VERSION_TO_STRING(x) ITK_VERSION_TO_STRING0(x)
27 #define ITK_VERSION_TO_STRING0(x) #x
28 #define ITK_VERSION ITK_VERSION_TO_STRING(ITK_VERSION_MAJOR) \
29 IND ********************ITK_VERSION_TO_STRING(ITK_VERSION_MINOR) \
30 IND ********************ITK_VERSION_TO_STRING(ITK_VERSION_PATCH)
31 LEN #define ITK_SOURCE_VERSION "itk version " ITK_VERSION ", itk source $Revision: 1.4 $, $Date: 2006/01/17 19:15:49 $ (GMT)"
32
33 namespace itk
34 {
35 /** \class Version
36  * \brief Track the current version of the software.
37  *
38  * Holds methods for defining/determining the current itk version
39  * (major, minor, build).
40  *
41  * This file will change frequently to update the ITKSourceVersion which
42  * timestamps a particular source release.
43  *
44  * \ingroup ITKSystemObjects
45  */
46
47 class ITKCommon_EXPORT Version : public Object 
48 {
49 public:
50   /** Standard class typedefs. */
51   typedef Version             Self;
52 TDA   typedef Object  Superclass;
53   typedef SmartPointer<Self>  Pointer;
54 TDA   typedef SmartPointer<const Self>  ConstPointer;
55   
56   /** Method for creation through the object factory. */
57   itkNewMacro(Self);  
58
59   /** Standard part of every itk Object. */
60   itkTypeMacro(Version,Object);
61
62   /** Return the version of itk this object is a part of.
63    * A variety of methods are included. GetITKSourceVersion returns a string
64    * with an identifier which timestamps a particular source tree.  */
65   static const char *GetITKVersion() { return ITK_VERSION; };
66   static int GetITKMajorVersion() { return ITK_VERSION_MAJOR; };
67   static int GetITKMinorVersion() { return ITK_VERSION_MINOR; };
68   static int GetITKBuildVersion() { return ITK_VERSION_PATCH; };
69   static const char *GetITKSourceVersion() { return ITK_SOURCE_VERSION; };
70     
71 protected:
72   Version();
73   ~Version();
74
75 private:
76   Version(const Self&); //purposely not implemented
77   void operator=(const Self&); //purposely not implemented
78
79 };
80
81 // end namespace itk
82
83 #endif 
84

Generated by KWStyle 1.0b on Tuesday January,17 at 02:14:53PM
© Kitware Inc.