PSCF v1.3
SystemConstRefReal.tpp
1#ifndef PRDC_SYSTEM_CONST_REF_REAL_TPP
2#define PRDC_SYSTEM_CONST_REF_REAL_TPP
3
4/*
5* PSCF - Polymer Self-Consistent Field
6*
7* Copyright 2015 - 2025, The Regents of the University of Minnesota
8* Distributed under the terms of the GNU General Public License.
9*/
10
11#include "SystemConstRefReal.h"
12
13namespace Pscf {
14namespace Prdc {
15
16 /*
17 * Default constructor.
18 */
19 template <class ST>
21 : systemPtr_(nullptr),
22 mixturePtr_(nullptr),
23 interactionPtr_(nullptr),
24 domainPtr_(nullptr),
25 cPtr_(nullptr),
26 wPtr_(nullptr),
27 hPtr_(nullptr),
28 maskPtr_(nullptr),
29 fileMasterPtr_(nullptr)
30 {}
31
32 /*
33 * Constructor (creates associations).
34 */
35 template <class ST>
37 : systemPtr_(nullptr),
38 mixturePtr_(nullptr),
39 interactionPtr_(nullptr),
40 domainPtr_(nullptr),
41 cPtr_(nullptr),
42 wPtr_(nullptr),
43 hPtr_(nullptr),
44 maskPtr_(nullptr),
45 fileMasterPtr_(nullptr)
46 { associate(system); }
47
48 /*
49 * Destructor.
50 */
51 template <class ST>
54
55 template <class ST>
57 {
58 systemPtr_ = &system;
59 mixturePtr_ = &(system.mixture());
60 interactionPtr_ = &(system.interaction());
61 domainPtr_ = &(system.domain());
62 cPtr_ = &(system.c());
63 wPtr_ = &(system.w());
64 hPtr_ = &(system.h());
65 maskPtr_ = &(system.mask());
66 fileMasterPtr_ = &(system.fileMaster());
67 }
68
69} // namespace Prdc
70} // namespace Pscf
71#endif
SystemT const & system() const
Get the associated System.
void associate(SystemT const &system)
Create associations with a system and its components.
SystemConstRefReal()
Default constructor.
Periodic fields and crystallography.
Definition CField.cpp:11
PSCF package top-level namespace.
Definition param_pc.dox:1