PSCF v1.5.0
EnvironmentFactory.h
1#ifndef RP_ENVIRONMENT_FACTORY_H
2#define RP_ENVIRONMENT_FACTORY_H
3
4/*
5* PSCF - Polymer Self-Consistent Field
6*
7* Copyright 2015 - 2026, David Morse (morse012@um.edu) and co-authors
8* Distributed under the terms of the GNU General Public License.
9*/
10
11#include <util/param/Factory.h> // base class template
12#include <rp/environment/Environment.h> // base class argument
13#include <pscf/backend/TmplDeclare.h> // preprocessor macros
14
15#include <string>
16
17// Forward declarations
18namespace Pscf {
19 namespace Rp {
20 template <int D, class T> class System;
21 template <int D, class T> class Simulator;
22 }
23}
24
25namespace Pscf {
26namespace Rp {
27
28
29 using namespace Util;
30
36
37 template <int D, class T>
38 class EnvironmentFactory : public Factory<Environment>
39 {
40
41 public:
42
49
56 Environment* factory(const std::string &className) const;
57
58 private:
59
61 System<D,T>* sysPtr_;
62
63 };
64
65 // Explicit instantation declarations
66 PSCF_TMPL_DECLARE(EnvironmentFactory)
67
68}
69}
70#endif
Factory for subclasses of Environment.
EnvironmentFactory(System< D, T > &system)
Constructor.
Environment * factory(const std::string &className) const
Method to create any Environment supplied with PSCF.
Environment generator for variable-cell SCFT.
Definition Environment.h:59
Base class for field theoretic PS-FTS simulator.
Definition Simulator.h:93
Base class template for classes that represent a complete system.
Code for programs that simulate real-valued periodic fields.
Definition param_pc.dox:2
PSCF package top-level namespace.