freESStrategicParameter.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   F.R.E.E. - flexible registration evaluation engine
00004   Version:   v.1.0.0
00005   Date:      $Date: 2006/09/01 12:00:00 $
00006   Module:    $RCSfile: freESStrategicParameter.h,v $
00007   Language:  C++
00008 
00009 
00010 
00011   Copyright (c) 2007 Ralf o Floca (Department of Medical Informatics,
00012   Institute for Medical Biometry and Informatics, University of Heidelberg,
00013   Germany). All rights reserved.
00014   See FREECopyright.txt or http://www.mi.med.uni-hd.de/free/copyright.htm
00015   for details.
00016 
00017      This software is distributed WITHOUT ANY WARRANTY; without even 
00018      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00019      PURPOSE.  See the above copyright notices for more information.
00020 
00021 =========================================================================*/
00022 #ifndef __freESStrategicParameter_h
00023 #define __freESStrategicParameter_h
00024 
00025 #include "itkLightObject.h"
00026 
00027 namespace FREE
00028 {
00029 
00030   namespace ES
00031   {
00035     template <class TValueType>
00036     class ITK_EXPORT StrategicParameter :
00037       public itk::LightObject
00038     {
00039     public:
00040       /* Standard class typedefs. */
00041       typedef StrategicParameter<TValueType> Self;
00042       typedef itk::LightObject Superclass;
00043       typedef itk::SmartPointer<Self> Pointer;
00044       typedef itk::SmartPointer<const Self> ConstPointer;
00045 
00046       /* Method for creation through the object factory. */
00047       itkNewMacro(Self);
00048 
00049       /* Run-time type information (and related methods). */
00050       itkTypeMacro(StrategicParameter, LightObject);
00051 
00052       /* Other typedefs */
00053       typedef TValueType ParameterValueType;
00054       typedef std::string OriginIDType;
00055 
00056       enum HandlingType
00057       { 
00058         HStatic, //* Parameter should not be changed by recombination or mutation
00059         HDynamic //* Parameter can be changed by recombination or mutation
00060       };
00061 
00062       bool operator == (const ParameterValueType& value) const {return value==m_Value;};
00063 
00064       void operator = (const ParameterValueType& value) {m_Value = value;};
00065       void operator = (const Self& parameter);
00066 
00067       operator ParameterValueType () const {return m_Value;};
00068       operator ParameterValueType& () {return m_Value;};
00069 
00070       ParameterValueType& GetValue() {return m_Value;};
00071       const ParameterValueType& GetValue() const {return m_Value;};
00072       void SetValue(const ParameterValueType& value) { m_Value = value;};
00073 
00074       const OriginIDType& GetOrigin() const {return m_Origin;};
00075       void SetOrigin(const OriginIDType& origin) { m_Origin = origin;};
00076 
00077       const HandlingType& GetHandling() const {return m_Handling;};
00078       void SetHandling(const HandlingType& handling) { m_Handling = handling;};
00079 
00080       Pointer Clone() const;
00081 
00082     protected:
00083       ParameterValueType m_Value;
00084       OriginIDType m_Origin;
00085       HandlingType m_Handling;
00086 
00089       StrategicParameter(){}
00090       virtual ~StrategicParameter(){}
00091 
00092     private:
00093       StrategicParameter(Self const&); // Purposely not implemented.
00094     };
00095 
00096   } //end namspsace ES
00097 } // end namespace FREE
00098 
00099 #ifndef ITK_MANUAL_INSTANTIATION
00100 #include "freESStrategicParameter.txx"
00101 #endif
00102 
00103 #endif // __freESStrategicParameter_h

Generated at Sat Oct 13 15:53:48 2007 for f.r.e.e. - Flexible Registration and Evaluation Engine by doxygen 1.5.3 written by Dimitri van Heesch, © 1997-2000