| 1 |
< |
/* |
| 1 |
> |
/* |
| 2 |
|
* Copyright (c) 2005 The University of Notre Dame. All Rights Reserved. |
| 3 |
|
* |
| 4 |
|
* The University of Notre Dame grants you ("Licensee") a |
| 46 |
|
|
| 47 |
|
namespace oopse { |
| 48 |
|
|
| 49 |
< |
class Integrator; |
| 50 |
< |
class SimInfo; |
| 51 |
< |
/** |
| 52 |
< |
* @class Integrator |
| 53 |
< |
* @todo document |
| 54 |
< |
*/ |
| 55 |
< |
class IntegratorCreator { |
| 56 |
< |
public: |
| 57 |
< |
IntegratorCreator(const std::string& ident) : ident_(ident) {} |
| 58 |
< |
virtual ~IntegratorCreator() {} |
| 59 |
< |
const std::string& getIdent() const { return ident_; } |
| 49 |
> |
class Integrator; |
| 50 |
> |
class SimInfo; |
| 51 |
> |
/** |
| 52 |
> |
* @class Integrator |
| 53 |
> |
* @todo document |
| 54 |
> |
*/ |
| 55 |
> |
class IntegratorCreator { |
| 56 |
> |
public: |
| 57 |
> |
IntegratorCreator(const std::string& ident) : ident_(ident) {} |
| 58 |
> |
virtual ~IntegratorCreator() {} |
| 59 |
> |
const std::string& getIdent() const { return ident_; } |
| 60 |
|
|
| 61 |
< |
virtual Integrator* create(SimInfo* info) const = 0; |
| 61 |
> |
virtual Integrator* create(SimInfo* info) const = 0; |
| 62 |
|
|
| 63 |
< |
private: |
| 64 |
< |
std::string ident_; |
| 65 |
< |
}; |
| 63 |
> |
private: |
| 64 |
> |
std::string ident_; |
| 65 |
> |
}; |
| 66 |
|
|
| 67 |
< |
/** |
| 68 |
< |
* @class IntegratorBuilder |
| 69 |
< |
* @todo document |
| 70 |
< |
*/ |
| 71 |
< |
template<class ConcreteIntegrator> |
| 72 |
< |
class IntegratorBuilder : public IntegratorCreator { |
| 73 |
< |
public: |
| 74 |
< |
IntegratorBuilder(const std::string& ident) : IntegratorCreator(ident) {} |
| 75 |
< |
virtual Integrator* create(SimInfo* info) const {return new ConcreteIntegrator(info);} |
| 76 |
< |
}; |
| 67 |
> |
/** |
| 68 |
> |
* @class IntegratorBuilder |
| 69 |
> |
* @todo document |
| 70 |
> |
*/ |
| 71 |
> |
template<class ConcreteIntegrator> |
| 72 |
> |
class IntegratorBuilder : public IntegratorCreator { |
| 73 |
> |
public: |
| 74 |
> |
IntegratorBuilder(const std::string& ident) : IntegratorCreator(ident) {} |
| 75 |
> |
virtual Integrator* create(SimInfo* info) const {return new ConcreteIntegrator(info);} |
| 76 |
> |
}; |
| 77 |
|
|
| 78 |
|
} |
| 79 |
|
|