VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkVersion.h 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00026 #ifndef __vtkVersion_h 00027 #define __vtkVersion_h 00028 00029 00030 #include "vtkObject.h" 00031 00032 #if VTK_MINOR_VERSION & 1 00033 # include <vtksys/DateStamp.h> // For date stamp 00034 # define VTK_SOURCE_VERSION "vtk version " VTK_VERSION ", Date: " vtksys_DATE_STAMP_STRING 00035 #else 00036 # define VTK_SOURCE_VERSION "vtk version " VTK_VERSION 00037 #endif 00038 00039 00040 class VTK_COMMON_EXPORT vtkVersion : public vtkObject 00041 { 00042 public: 00043 static vtkVersion *New(); 00044 vtkTypeMacro(vtkVersion,vtkObject); 00045 00047 00050 static const char *GetVTKVersion() { return VTK_VERSION; } 00051 static int GetVTKMajorVersion() { return VTK_MAJOR_VERSION; } 00052 static int GetVTKMinorVersion() { return VTK_MINOR_VERSION; } 00053 static int GetVTKBuildVersion() { return VTK_BUILD_VERSION; } 00054 static const char *GetVTKSourceVersion() { return VTK_SOURCE_VERSION; } 00056 00057 protected: 00058 vtkVersion() {}; //insure constructor/destructor protected 00059 ~vtkVersion() {}; 00060 private: 00061 vtkVersion(const vtkVersion&); // Not implemented. 00062 void operator=(const vtkVersion&); // Not implemented. 00063 }; 00064 00065 #endif 00066