PSCF v1.5.0
McMoveFactory.h
1#ifndef RP_MC_MOVE_FACTORY_H
2#define RP_MC_MOVE_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/fts/montecarlo/McMove.h> // base class argument
13
14#include <pscf/backend/TmplDeclare.h>
15
16#include <string>
17
18namespace Pscf {
19namespace Rp {
20
21 // Forward declaration
22 template <int D, class T> class McSimulator;
23
24 using namespace Util;
25
31 template <int D, class T>
32 class McMoveFactory : public Factory< McMove<D,T> >
33 {
34
35 public:
36
43
50 McMove<D,T>* factory(const std::string &className) const;
51
53
54 private:
55
57 McSimulator<D,T>* simulatorPtr_;
58
59 };
60
61 // Explicit instantiation declarations
62 PSCF_TMPL_DECLARE(McMoveFactory)
63
64}
65}
66#endif
Factory for subclasses of McMove.
McMoveFactory(McSimulator< D, T > &simulator)
Constructor.
McMove< D, T > * factory(const std::string &className) const
Method to create any McMove supplied with PSCF.
McMove is an abstract base class for Monte Carlo moves.
Definition McMove.h:50
Monte-Carlo simulation coordinator.
Definition McSimulator.h:55
McMove< D, T > * trySubfactories(const std::string &className) const
Definition Factory.h:427
Code for programs that simulate real-valued periodic fields.
Definition param_pc.dox:2
PSCF package top-level namespace.