EvilBase_def.hpp

Go to the documentation of this file.
00001 #ifndef EVIL_BASE_DEF_HPP
00002 #define EVIL_BASE_DEF_HPP
00003 
00004 
00005 #include "EvilBase_decl.hpp"
00006 
00007 // Include the subclasses that we are going to instantiate in the factory
00008 // (i.e. evil)!  NOTE: We need to include the possible function definitions
00009 // here in case we are doing implicit instantiation!
00010 #include "AEvil.hpp"
00011 #include "BEvil.hpp"
00012 
00013 
00014 namespace EvilPack {
00015 
00016 
00017 template<class T>
00018 EvilBase<T>::~EvilBase()
00019 {}
00020 
00021 
00022 template<class T>
00023 RCP<EvilBase<T> >
00024 EvilBase<T>::createEvil(const std::string& concreteEvilName)
00025 {
00026   if (concreteEvilName == "AEvil") {
00027     return aEvil<T>();
00028   }
00029   else if (concreteEvilName == "BEvil") {
00030     return bEvil<T>();
00031   }
00032   else {
00033     TEST_FOR_EXCEPT(true);
00034   }
00035   return Teuchos::null; // Never be executed
00036 }
00037 
00038 
00039 } // namespace EvilPack
00040 
00041 
00042 #endif // EVIL_BASE_DEF_HPP
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on Tue Oct 20 10:13:59 2009 for Teuchos Package Browser (Single Doxygen Collection) by  doxygen 1.6.1