1 //=============================================================================
2 // File : SMESH_HypothesisCreator.hxx
3 // Created : lun mai 27 15:28:35 CEST 2002
4 // Author : Paul RASCLE, EDF
6 // Copyright : EDF 2002
8 //=============================================================================
10 #ifndef _SMESH_HYPOTHESISCREATOR_HXX_
11 #define _SMESH_HYPOTHESISCREATOR_HXX_
13 #include "SMESH_HypothesisFactory.hxx"
17 //=============================================================================
19 * Specific Hypothesis Creators are generated with a template which inherits a
20 * generic hypothesis creator. Each creator returns an hypothesis of the type
21 * given in the template.
23 //=============================================================================
25 template <class T> class SMESH_HypothesisCreator
26 : public GenericHypothesisCreator
29 // map<int, T*> _instances;
31 // virtual T* GetInstance(int hypId)
33 // if (_instances.find(hypId) != _instances.end())
34 // return _instances[hypId];
39 virtual T* Create (int hypId, int studyId, SMESH_Gen* gen)
41 T* anInstance= new T(hypId, studyId, gen);
42 // _gen->StoreHypothesisInstance(anInstance);
43 // _instances[hypId] = anInstance;