PSCF v1.5.0
CompressorFactory.h
1#ifndef RP_COMPRESSOR_FACTORY_H
2#define RP_COMPRESSOR_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/compressor/Compressor.h> // base class argument
13#include <pscf/backend/TmplDeclare.h> // preprocessor macros
14
15#include <string>
16
17namespace Pscf {
18namespace Rp {
19
20 // Forward declaration
21 template <int D, class T> class System;
22
23 using namespace Util;
24
30
31 template <int D, class T>
33 : public Factory< Compressor<D,T> >
34 {
35
36 public:
37
40
47 Compressor<D,T>* factory(const std::string &className) const;
48
50
51 private:
52
54 System<D,T>* sysPtr_;
55
57 using FactoryT = Factory< Compressor<D,T> >;
58
59 };
60
61 // Explicit instantation declarations
62 PSCF_TMPL_DECLARE(CompressorFactory)
63
64}
65}
66#endif
Factory for subclasses of Compressor.
Compressor< D, T > * factory(const std::string &className) const
Method to create any Compressor supplied with PSCF.
CompressorFactory(System< D, T > &system)
Constructor.
Base class for iterators that impose incompressibility.
Definition Compressor.h:35
Base class template for classes that represent a complete system.
Compressor< D, T > * trySubfactories(const std::string &className) const
Code for programs that simulate real-valued periodic fields.
Definition param_pc.dox:2
PSCF package top-level namespace.