00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00030 #ifndef __itkMacro_h
00031 #define __itkMacro_h
00032
00033 #include "itkWin32Header.h"
00034 #include "itkConfigure.h"
00035
00036 #include <string>
00037
00038
00039 #if !defined(CMAKE_NO_ANSI_STRING_STREAM)
00040 # include <sstream>
00041 #elif !defined(CMAKE_NO_ANSI_STREAM_HEADERS)
00042 # include <strstream>
00043 # define ITK_NO_ANSI_STRING_STREAM
00044 #else
00045 # include <strstream.h>
00046 # define ITK_NO_ANSI_STRING_STREAM
00047 #endif
00048
00053 namespace itk
00054 {
00055 }
00056
00059 #define itkNotUsed(x)
00060
00075 #if defined(_MSC_VER) && (_MSC_VER <= 1300)
00076 # define ITK_NO_INCLASS_MEMBER_INITIALIZATION
00077 #endif
00078 #if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x540)
00079 # define ITK_NO_INCLASS_MEMBER_INITIALIZATION
00080 #endif
00081 #if defined(__SVR4) && !defined(__SUNPRO_CC)
00082 # define ITK_NO_INCLASS_MEMBER_INITIALIZATION
00083 #endif
00084
00085
00086
00087
00088
00089
00090
00091
00092 #if defined(__GNUC__)
00093 # define ITK_NO_SIZEOF_CONSTANT_LOOKUP
00094 #endif
00095
00096 #if defined(_MSC_VER) && (_MSC_VER <= 1300)
00097 #define ITK_NO_SELF_AS_TRAIT_IN_TEMPLATE_ARGUMENTS
00098 #endif
00099
00100 #if defined(ITK_NO_INCLASS_MEMBER_INITIALIZATION) || \
00101 defined(ITK_NO_SIZEOF_CONSTANT_LOOKUP)
00102 # define itkStaticConstMacro(name,type,value) enum { name = value }
00103 #else
00104 # define itkStaticConstMacro(name,type,value) static const type name = value
00105 #endif
00106
00107 #ifdef ITK_NO_SELF_AS_TRAIT_IN_TEMPLATE_ARGUMENTS
00108 # define itkGetStaticConstMacro(name) name
00109 #else
00110 # define itkGetStaticConstMacro(name) (Self::name)
00111 #endif
00112
00114 #define itkSetInputMacro(name, type, number) \
00115 virtual void Set##name##Input(const type *_arg) \
00116 { \
00117 itkDebugMacro("setting input " #name " to " << _arg); \
00118 if (_arg != static_cast<type *>(this->ProcessObject::GetInput( number ))) \
00119 { \
00120 this->ProcessObject::SetNthInput( number, const_cast<type *>(_arg) ); \
00121 this->Modified(); \
00122 } \
00123 } \
00124 virtual void SetInput##number(const type *_arg) \
00125 { \
00126 itkDebugMacro("setting input " #number " to " << _arg); \
00127 if (_arg != static_cast<type *>(this->ProcessObject::GetInput( number ))) \
00128 { \
00129 this->ProcessObject::SetNthInput( number, const_cast<type *>(_arg) ); \
00130 this->Modified(); \
00131 } \
00132 }
00133
00134
00136 #define itkSuperclassTraitMacro(traitnameType) \
00137 typedef typename Superclass::traitnameType traitnameType;
00138
00140 #define itkGetInputMacro(name, type, number) \
00141 virtual const type * Get##name##Input() const \
00142 { \
00143 itkDebugMacro("returning input " << #name " of " << static_cast<const type *>(this->ProcessObject::GetInput( number )) ); \
00144 return static_cast<const type *>(this->ProcessObject::GetInput( number )); \
00145 } \
00146 virtual const type * GetInput##number() const \
00147 { \
00148 itkDebugMacro("returning input " << #number " of " << static_cast<const type *>(this->ProcessObject::GetInput( number )) ); \
00149 return static_cast<const type *>(this->ProcessObject::GetInput( number )); \
00150 }
00151
00152
00155 #define itkSetDecoratedInputMacro(name, type, number) \
00156 itkSetInputMacro(name, SimpleDataObjectDecorator<type>, number); \
00157 itkGetInputMacro(name, SimpleDataObjectDecorator<type>, number); \
00158 virtual void Set##name(const type &_arg) \
00159 { \
00160 typedef SimpleDataObjectDecorator< type > DecoratorType; \
00161 itkDebugMacro("setting input " #name " to " << _arg); \
00162 const DecoratorType * oldInput = \
00163 static_cast< const DecoratorType * >( \
00164 this->ProcessObject::GetInput(number) ); \
00165 if( oldInput && oldInput->Get() == _arg ) \
00166 { \
00167 return; \
00168 } \
00169 typename DecoratorType::Pointer newInput = DecoratorType::New(); \
00170 newInput->Set( _arg ); \
00171 this->Set##name##Input( newInput ); \
00172 }
00173
00174
00178 #define itkSetDecoratedObjectInputMacro(name, type, number) \
00179 itkSetInputMacro(name, DataObjectDecorator<type>, number); \
00180 itkGetInputMacro(name, DataObjectDecorator<type>, number); \
00181 virtual void Set##name(const type *_arg) \
00182 { \
00183 typedef DataObjectDecorator< type > DecoratorType; \
00184 itkDebugMacro("setting input " #name " to " << _arg); \
00185 const DecoratorType * oldInput = \
00186 static_cast< const DecoratorType * >( \
00187 this->ProcessObject::GetInput(number) ); \
00188 if( oldInput && oldInput->Get() == _arg ) \
00189 { \
00190 return; \
00191 } \
00192 typename DecoratorType::Pointer newInput = DecoratorType::New(); \
00193 newInput->Set( _arg ); \
00194 this->Set##name##Input( newInput ); \
00195 }
00196
00197
00198
00200 #define itkSetMacro(name,type) \
00201 virtual void Set##name (const type _arg) \
00202 { \
00203 itkDebugMacro("setting " #name " to " << _arg); \
00204 if (this->m_##name != _arg) \
00205 { \
00206 this->m_##name = _arg; \
00207 this->Modified(); \
00208 } \
00209 }
00210
00211
00213 #define itkGetMacro(name,type) \
00214 virtual type Get##name () \
00215 { \
00216 itkDebugMacro("returning " << #name " of " << this->m_##name ); \
00217 return this->m_##name; \
00218 }
00219
00220
00224 #define itkGetConstMacro(name,type) \
00225 virtual type Get##name () const \
00226 { \
00227 itkDebugMacro("returning " << #name " of " << this->m_##name ); \
00228 return this->m_##name; \
00229 }
00230
00231
00236 #define itkGetConstReferenceMacro(name,type) \
00237 virtual const type & Get##name () const \
00238 { \
00239 itkDebugMacro("returning " << #name " of " << this->m_##name ); \
00240 return this->m_##name; \
00241 }
00242
00243
00247 #define itkSetEnumMacro(name,type) \
00248 virtual void Set##name (const type _arg) \
00249 { \
00250 itkDebugMacro("setting " #name " to " << static_cast<long>(_arg)); \
00251 if (this->m_##name != _arg) \
00252 { \
00253 this->m_##name = _arg; \
00254 this->Modified(); \
00255 } \
00256 }
00257
00258
00262 #define itkGetEnumMacro(name,type) \
00263 virtual type Get##name () const \
00264 { \
00265 itkDebugMacro("returning " << #name " of " << static_cast<long>(this->m_##name) ); \
00266 return this->m_##name; \
00267 }
00268
00269
00273 #define itkSetStringMacro(name) \
00274 virtual void Set##name (const char* _arg) \
00275 { \
00276 if ( _arg && (_arg == this->m_##name) ) { return;} \
00277 if (_arg) \
00278 { \
00279 this->m_##name = _arg;\
00280 } \
00281 else \
00282 { \
00283 this->m_##name = ""; \
00284 } \
00285 this->Modified(); \
00286 } \
00287 virtual void Set##name (const std::string & _arg) \
00288 { \
00289 this->Set##name( _arg.c_str() ); \
00290 } \
00291
00292
00293
00297 #define itkGetStringMacro(name) \
00298 virtual const char* Get##name () const \
00299 { \
00300 return this->m_##name.c_str(); \
00301 }
00302
00306 #define itkSetClampMacro(name,type,min,max) \
00307 virtual void Set##name (type _arg) \
00308 { \
00309 itkDebugMacro("setting " << #name " to " << _arg ); \
00310 if (this->m_##name != (_arg<min?min:(_arg>max?max:_arg))) \
00311 { \
00312 this->m_##name = (_arg<min?min:(_arg>max?max:_arg)); \
00313 this->Modified(); \
00314 } \
00315 }
00316
00317
00322 #define itkSetObjectMacro(name,type) \
00323 virtual void Set##name (type* _arg) \
00324 { \
00325 itkDebugMacro("setting " << #name " to " << _arg ); \
00326 if (this->m_##name != _arg) \
00327 { \
00328 this->m_##name = _arg; \
00329 this->Modified(); \
00330 } \
00331 }
00332
00333
00336 #define itkGetObjectMacro(name,type) \
00337 virtual type * Get##name () \
00338 { \
00339 itkDebugMacro("returning " #name " address " << this->m_##name ); \
00340 return this->m_##name.GetPointer(); \
00341 }
00342
00343
00348 #define itkSetConstObjectMacro(name,type) \
00349 virtual void Set##name (const type* _arg) \
00350 { \
00351 itkDebugMacro("setting " << #name " to " << _arg ); \
00352 if (this->m_##name != _arg) \
00353 { \
00354 this->m_##name = _arg; \
00355 this->Modified(); \
00356 } \
00357 }
00358
00359
00360
00363 #define itkGetConstObjectMacro(name,type) \
00364 virtual const type * Get##name () const \
00365 { \
00366 itkDebugMacro("returning " #name " address " << this->m_##name ); \
00367 return this->m_##name.GetPointer(); \
00368 }
00369
00370
00373 #define itkGetConstReferenceObjectMacro(name,type) \
00374 virtual const typename type::Pointer & Get##name () const \
00375 { \
00376 itkDebugMacro("returning " #name " address " << this->m_##name ); \
00377 return this->m_##name; \
00378 }
00379
00380
00383 #define itkBooleanMacro(name) \
00384 virtual void name##On () { this->Set##name(true);} \
00385 virtual void name##Off () { this->Set##name(false);}
00386
00387
00391 #define itkSetVectorMacro(name,type,count) \
00392 virtual void Set##name(type data[]) \
00393 { \
00394 unsigned int i; \
00395 for (i=0; i<count; i++) { if ( data[i] != this->m_##name[i] ) { break; }} \
00396 if ( i < count ) \
00397 { \
00398 this->Modified(); \
00399 for (i=0; i<count; i++) { this->m_##name[i] = data[i]; }\
00400 } \
00401 }
00402
00403
00406 #define itkGetVectorMacro(name,type,count) \
00407 virtual type *Get##name () const \
00408 { \
00409 return this->m_##name; \
00410 }
00411
00428 #define itkNewMacro(x) \
00429 static Pointer New(void) \
00430 { \
00431 Pointer smartPtr = ::itk::ObjectFactory<x>::Create(); \
00432 if(smartPtr.GetPointer() == NULL) \
00433 { \
00434 smartPtr = new x; \
00435 } \
00436 smartPtr->UnRegister(); \
00437 return smartPtr; \
00438 } \
00439 virtual ::itk::LightObject::Pointer CreateAnother(void) const \
00440 { \
00441 ::itk::LightObject::Pointer smartPtr; \
00442 smartPtr = x::New().GetPointer(); \
00443 return smartPtr; \
00444 }
00445
00446
00447
00464 #define itkFactorylessNewMacro(x) \
00465 static Pointer New(void) \
00466 { \
00467 Pointer smartPtr; \
00468 x *rawPtr = new x; \
00469 smartPtr = rawPtr; \
00470 rawPtr->UnRegister(); \
00471 return smartPtr; \
00472 } \
00473 virtual LightObject::Pointer CreateAnother(void) const \
00474 { \
00475 LightObject::Pointer smartPtr; \
00476 smartPtr = x::New().GetPointer(); \
00477 return smartPtr; \
00478 }
00479
00480
00483 #define itkTypeMacro(thisClass,superclass) \
00484 virtual const char *GetNameOfClass() const \
00485 {return #thisClass;}
00486
00487
00488 namespace itk
00489 {
00496 extern ITKCommon_EXPORT void OutputWindowDisplayText(const char*);
00497 extern ITKCommon_EXPORT void OutputWindowDisplayErrorText(const char*);
00498 extern ITKCommon_EXPORT void OutputWindowDisplayWarningText(const char*);
00499 extern ITKCommon_EXPORT void OutputWindowDisplayGenericOutputText(const char*);
00500 extern ITKCommon_EXPORT void OutputWindowDisplayDebugText(const char*);
00501 }
00503
00507 #if defined(ITK_LEAN_AND_MEAN) || defined(__BORLANDC__)
00508 #define itkDebugMacro(x)
00509 #else
00510 #define itkDebugMacro(x) \
00511 { if (this->GetDebug() && ::itk::Object::GetGlobalWarningDisplay()) \
00512 { ::itk::OStringStream itkmsg; \
00513 itkmsg << "Debug: In " __FILE__ ", line " << __LINE__ << "\n" \
00514 << this->GetNameOfClass() << " (" << this << "): " x \
00515 << "\n\n"; \
00516 ::itk::OutputWindowDisplayDebugText(itkmsg.str().c_str());} \
00517 }
00518 #endif
00519
00520
00521
00525 #ifdef ITK_LEAN_AND_MEAN
00526 #define itkWarningMacro(x)
00527 #else
00528 #define itkWarningMacro(x) \
00529 { if (::itk::Object::GetGlobalWarningDisplay()) \
00530 { ::itk::OStringStream itkmsg; \
00531 itkmsg << "WARNING: In " __FILE__ ", line " << __LINE__ << "\n" \
00532 << this->GetNameOfClass() << " (" << this << "): " x \
00533 << "\n\n"; \
00534 ::itk::OutputWindowDisplayWarningText(itkmsg.str().c_str());} \
00535 }
00536 #endif
00537
00538
00539 namespace itk
00540 {
00541
00547 #if !defined(ITK_NO_ANSI_STRING_STREAM)
00548 class OStringStream: public std::ostringstream
00549 {
00550 public:
00551 OStringStream() {}
00552 private:
00553 OStringStream(const OStringStream&);
00554 void operator=(const OStringStream&);
00555 };
00556 #else
00557 namespace OStringStreamDetail
00558 {
00559 class Cleanup
00560 {
00561 public:
00562 Cleanup(std::ostrstream& ostr): m_OStrStream(ostr) {}
00563 ~Cleanup() { m_OStrStream.rdbuf()->freeze(0); }
00564 static void IgnoreUnusedVariable(const Cleanup&) {}
00565 protected:
00566 std::ostrstream& m_OStrStream;
00567 };
00568 }
00570
00571 class OStringStream: public std::ostrstream
00572 {
00573 public:
00574 typedef std::ostrstream Superclass;
00575 OStringStream() {}
00576 std::string str()
00577 {
00578 OStringStreamDetail::Cleanup cleanup(*this);
00579 OStringStreamDetail::Cleanup::IgnoreUnusedVariable(cleanup);
00580 int pcount = this->pcount();
00581 const char* ptr = this->Superclass::str();
00582 return std::string(ptr?ptr:"", pcount);
00583 }
00584 private:
00585 OStringStream(const OStringStream&);
00586 void operator=(const OStringStream&);
00587 };
00588 #endif
00589
00590 }
00591
00592 #if defined(ITK_CPP_FUNCTION)
00593 #if defined(__BORLANDC__)
00594 #define ITK_LOCATION __FUNC__
00595 #elif defined(_WIN32) && !defined(__MINGW32__) && !defined(__CYGWIN__) && !defined(CABLE_CONFIGURATION) && !defined(CSWIG)
00596 #define ITK_LOCATION __FUNCSIG__
00597 #elif defined(__GNUC__)
00598 #define ITK_LOCATION __PRETTY_FUNCTION__
00599 #else
00600 #define ITK_LOCATION __FUNCTION__
00601 #endif
00602 #else
00603 #define ITK_LOCATION "unknown"
00604 #endif
00605
00606 #include "itkExceptionObject.h"
00607
00611 #define itkExceptionMacro(x) \
00612 { \
00613 ::itk::OStringStream message; \
00614 message << "itk::ERROR: " << this->GetNameOfClass() \
00615 << "(" << this << "): " x; \
00616 ::itk::ExceptionObject e_(__FILE__, __LINE__, message.str().c_str(),ITK_LOCATION); \
00617 throw e_; \
00618 }
00619
00620
00621 #define itkGenericExceptionMacro(x) \
00622 { \
00623 ::itk::OStringStream message; \
00624 message << "itk::ERROR: " x; \
00625 ::itk::ExceptionObject e_(__FILE__, __LINE__, message.str().c_str(),ITK_LOCATION); \
00626 throw e_; \
00627 }
00628
00629 #ifdef ITK_LEAN_AND_MEAN
00630 #define itkGenericOutputMacro(x)
00631 #else
00632 #define itkGenericOutputMacro(x) \
00633 { if (::itk::Object::GetGlobalWarningDisplay()) \
00634 { ::itk::OStringStream itkmsg; \
00635 itkmsg << "WARNING: In " __FILE__ ", line " << __LINE__ << "\n" \
00636 x << "\n\n"; \
00637 ::itk::OutputWindowDisplayGenericOutputText(itkmsg.str().c_str());} \
00638 }
00639 #endif
00640
00641
00642
00643
00644
00645
00646 #define itkLogMacro( x, y) \
00647 { \
00648 if (this->GetLogger() ) \
00649 { \
00650 this->GetLogger()->Write(::itk::LoggerBase::x, y); \
00651 } \
00652 }
00653
00654
00655 #define itkLogMacroStatic( obj, x, y) \
00656 { \
00657 if (obj->GetLogger() ) \
00658 { \
00659 obj->GetLogger()->Write(::itk::LoggerBase::x, y); \
00660 } \
00661 }
00662
00663
00664
00665
00666
00667
00668
00669
00670
00671
00672 #if defined(ITK_LEGACY_REMOVE)
00673
00674 # define itkLegacy(method)
00675 #elif defined(ITK_LEGACY_SILENT) || defined(ITK_WRAPPING_CXX)
00676
00677 # define itkLegacy(method) method
00678 #else
00679
00680
00681 # if defined(__GNUC__) && !defined(__INTEL_COMPILER) && (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1))
00682 # define itkLegacy(method) method __attribute__((deprecated))
00683 # elif defined(_MSC_VER) && _MSC_VER >= 1300
00684 # define itkLegacy(method) __declspec(deprecated) method
00685 # else
00686 # define itkLegacy(method) method
00687 # endif
00688 #endif
00689
00690
00691
00692
00693
00694
00695
00696
00697
00698
00699
00700
00701
00702
00703 #if defined(ITK_LEGACY_REMOVE) || defined(ITK_LEGACY_SILENT)
00704 # define itkLegacyBody(method, version)
00705 # define itkLegacyReplaceBody(method, version, replace)
00706 #else
00707 # define itkLegacyBody(method, version) \
00708 itkWarningMacro(#method " was deprecated for ITK " #version " and will be removed in a future version.")
00709 # define itkLegacyReplaceBody(method, version, replace) \
00710 itkWarningMacro(#method " was deprecated for ITK " #version " and will be removed in a future version. Use " #replace " instead.")
00711 #endif
00712
00713 #if defined(__INTEL_COMPILER)
00714 # pragma warning (disable: 193)
00715 #endif
00716
00717
00718
00719
00720
00721
00722
00723
00724
00725
00726
00727 #if defined(__sgi) && defined(_COMPILER_VERSION)
00728 # define ITK_TEMPLATE_DO_NOT_INSTANTIATE 1
00729 #elif defined(__INTEL_COMPILER) && __INTEL_COMPILER >= 700
00730 # define ITK_TEMPLATE_EXTERN 1
00731 #elif defined(__GNUC__) && __GNUC__ >= 3
00732 # define ITK_TEMPLATE_EXTERN 1
00733 #elif defined(_MSC_VER) && _MSC_VER >= 1300
00734 # define ITK_TEMPLATE_EXTERN 1
00735 #endif
00736 #if !defined(ITK_TEMPLATE_DO_NOT_INSTANTIATE)
00737 # define ITK_TEMPLATE_DO_NOT_INSTANTIATE 0
00738 #endif
00739 #if !defined(ITK_TEMPLATE_EXTERN)
00740 # define ITK_TEMPLATE_EXTERN 0
00741 #endif
00742
00743
00744
00745
00746
00747
00748
00749
00750 #define ITK_TEMPLATE_EXPORT(x) ITK_TEMPLATE_EXPORT_DELAY(x)
00751 #define ITK_TEMPLATE_EXPORT_DELAY(x) template ITK_TEMPLATE_##x;
00752
00753
00754
00755
00756
00757
00758
00759
00760
00761 #if ITK_TEMPLATE_EXTERN
00762 # define ITK_TEMPLATE_IMPORT_DELAY(x) extern template ITK_TEMPLATE_##x;
00763 # if defined(_MSC_VER)
00764 # pragma warning (disable: 4231)
00765 # endif
00766 #elif ITK_TEMPLATE_DO_NOT_INSTANTIATE
00767 # define ITK_TEMPLATE_IMPORT_DELAY(x) \
00768 ITK_TEMPLATE_IMPORT_IMPL(do_not_instantiate ITK_TEMPLATE_##x)
00769 # define ITK_TEMPLATE_IMPORT_IMPL(x) _Pragma(#x)
00770 #endif
00771 #if defined(ITK_TEMPLATE_IMPORT_DELAY)
00772 # define ITK_TEMPLATE_IMPORT(x) ITK_TEMPLATE_IMPORT_DELAY(x)
00773 # define ITK_TEMPLATE_IMPORT_WORKS 1
00774 #else
00775 # define ITK_TEMPLATE_IMPORT(x)
00776 # define ITK_TEMPLATE_IMPORT_WORKS 0
00777 #endif
00778
00779
00780
00781
00782
00783
00784
00785
00786
00787
00788
00789
00790
00791
00792
00793
00794
00795
00796
00797
00798
00799
00800
00801
00802
00803
00804
00805
00806
00807
00808
00809
00810
00811
00812
00813
00814
00815
00816
00817
00818
00819
00820
00821
00822
00823
00824
00825
00826
00827
00828
00829
00830
00831
00832
00833
00834
00835 #define ITK_EXPORT_TEMPLATE(EXPORT, c, x, y) \
00836 ITK_TEMPLATE_##c(ITK_TEMPLATE_EXPORT, EXPORT ITK_EMPTY, x, y)
00837 #define ITK_IMPORT_TEMPLATE(EXPORT, c, x, y) \
00838 ITK_TEMPLATE_##c(ITK_TEMPLATE_IMPORT, EXPORT ITK_EMPTY, x, y)
00839 #define ITK_EMPTY
00840
00841
00842
00843
00844
00845 #define ITK_TEMPLATE_1(x1) x1
00846 #define ITK_TEMPLATE_2(x1,x2) x1,x2
00847 #define ITK_TEMPLATE_3(x1,x2,x3) x1,x2,x3
00848 #define ITK_TEMPLATE_4(x1,x2,x3,x4) x1,x2,x3,x4
00849 #define ITK_TEMPLATE_5(x1,x2,x3,x4,x5) x1,x2,x3,x4,x5
00850 #define ITK_TEMPLATE_6(x1,x2,x3,x4,x5,x6) x1,x2,x3,x4,x5,x6
00851 #define ITK_TEMPLATE_7(x1,x2,x3,x4,x5,x6,x7) x1,x2,x3,x4,x5,x6,x7
00852 #define ITK_TEMPLATE_8(x1,x2,x3,x4,x5,x6,x7,x8) x1,x2,x3,x4,x5,x6,x7,x8
00853 #define ITK_TEMPLATE_9(x1,x2,x3,x4,x5,x6,x7,x8,x9) x1,x2,x3,x4,x5,x6,x7,x8,x9
00854
00855
00856
00857
00858
00859
00860
00861
00862
00863 #if defined(ITK_MANUAL_INSTANTIATION)
00864 # define ITK_TEMPLATE_TXX 0
00865 #else
00866 # define ITK_TEMPLATE_TXX !(ITK_TEMPLATE_CXX || ITK_TEMPLATE_TYPE)
00867 #endif
00868
00869
00870
00871
00872
00873
00874 #if ITK_TEMPLATE_CXX
00875 # undef ITK_MANUAL_INSTANTIATION
00876 # define ITK_MANUAL_INSTANTIATION
00877 # if defined(_MSC_VER)
00878 # pragma warning (disable: 4275)
00879 # pragma warning (disable: 4661)
00880 # endif
00881 #endif
00882
00883
00884
00885
00886 #define ITK_EXPORT_ITKCommon(c, x, n) \
00887 ITK_EXPORT_TEMPLATE(ITKCommon_EXPORT, c, x, n)
00888 #define ITK_IMPORT_ITKCommon(c, x, n) \
00889 ITK_IMPORT_TEMPLATE(ITKCommon_EXPORT, c, x, n)
00890
00891
00892
00893
00894
00895
00896
00897
00898
00899
00900
00901
00902
00903
00904 #if ITK_TEMPLATE_IMPORT_WORKS && defined(ITK_EXPLICIT_INSTANTIATION)
00905 # define ITK_TEMPLATE_EXPLICIT !ITK_TEMPLATE_CXX
00906 #else
00907 # define ITK_TEMPLATE_EXPLICIT 0
00908 #endif
00909
00910
00911
00912
00913
00914
00915
00916
00917 #if defined(__GNUC__)
00918 # if (((__GNUC__ == 2) && (__GNUC_MINOR__ >= 5)) || (__GNUC__ >= 3))
00919 # define ITK_NO_RETURN \
00920 __attribute__ ((noreturn))
00921 # endif
00922 #else
00923 # define ITK_NO_RETURN
00924 #endif
00925
00926
00927 #endif //end of itkMacro.h
00928