Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkFEMLoadTest.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkFEMLoadTest.h,v $
00005   Language:  C++
00006   Date:      $Date: 2003-09-10 14:29:43 $
00007   Version:   $Revision: 1.6 $
00008 
00009   Copyright (c) Insight Software Consortium. All rights reserved.
00010   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
00011 
00012      This software is distributed WITHOUT ANY WARRANTY; without even 
00013      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00014      PURPOSE.  See the above copyright notices for more information.
00015 
00016 =========================================================================*/
00017 
00018 #ifndef __itkFEMLoadTest_h
00019 #define __itkFEMLoadTest_h
00020 
00021 #include "itkFEMLoadElementBase.h"
00022 
00023 namespace itk {
00024 namespace fem {
00025 
00026 
00027 
00028 
00037 template<class TClass>
00038 class LoadTest : public LoadElement
00039 {
00040 FEM_CLASS(LoadTest,LoadElement)
00041 public:
00042 
00046   LoadTest() {}
00047 
00051   TClass data;
00052 
00053   virtual void Read( std::istream& f, void* info )
00054   {
00055     Superclass::Read(f,info);
00056   }
00057   void Write( std::ostream& f ) const
00058   {
00059     // call the parent's write function
00060     Superclass::Write(f);
00061   }
00062 
00063 private:
00066   static const int DummyCLID;
00067 
00068 };
00069 
00070 
00071 
00072 
00073 // Provide the templated code for CLID function, that is 
00074 // otherwise generated automaticly with FEM_CLASS_REGISTER
00075 // macro.
00076 template<class TClass>
00077 int LoadTest<TClass>::CLID(void) 
00078 {
00079   static const int CLID_ = FEMOF::Register( LoadTest::NewB, (std::string("LoadTest(")
00080                 +typeid(TClass).name()+")").c_str());
00081   return CLID_;
00082 }
00083 
00084 // Make sure that the class is registered with FEMObjectFactory
00085 // by calling CLID() static member function each time the class
00086 // is instantiated for a specific template parameter TClass.
00087 template<class TClass>
00088 const int LoadTest<TClass>::DummyCLID=LoadTest<TClass>::CLID();
00089 
00090 
00091 
00092 
00093 
00094 
00095 }} // end namespace itk::fem
00096 
00097 #endif // #ifndef __itkFEMLoadTest_h
00098 

Generated at Mon Apr 14 12:23:53 2008 for ITK by doxygen 1.5.1 written by Dimitri van Heesch, © 1997-2000