"platforms/vscode:/vscode.git/clone" did not exist on "c400a83b310a61413adf24b6139252eea012dbed"
SerializationProxyRegistration.cpp 10.3 KB
Newer Older
1
2
3
4
5
6
7
8
/* -------------------------------------------------------------------------- *
 *                                   OpenMM                                   *
 * -------------------------------------------------------------------------- *
 * This is part of the OpenMM molecular simulation toolkit originating from   *
 * Simbios, the NIH National Center for Physics-Based Simulation of           *
 * Biological Structures at Stanford, funded under the NIH Roadmap for        *
 * Medical Research, grant U54 GM072970. See https://simtk.org.               *
 *                                                                            *
9
 * Portions copyright (c) 2010-2016 Stanford University and the Authors.      *
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
 * Authors: Peter Eastman                                                     *
 * Contributors:                                                              *
 *                                                                            *
 * Permission is hereby granted, free of charge, to any person obtaining a    *
 * copy of this software and associated documentation files (the "Software"), *
 * to deal in the Software without restriction, including without limitation  *
 * the rights to use, copy, modify, merge, publish, distribute, sublicense,   *
 * and/or sell copies of the Software, and to permit persons to whom the      *
 * Software is furnished to do so, subject to the following conditions:       *
 *                                                                            *
 * The above copyright notice and this permission notice shall be included in *
 * all copies or substantial portions of the Software.                        *
 *                                                                            *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR *
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,   *
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL    *
 * THE AUTHORS, CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,    *
 * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR      *
 * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE  *
 * USE OR OTHER DEALINGS IN THE SOFTWARE.                                     *
 * -------------------------------------------------------------------------- */

32
#include "openmm/AndersenThermostat.h"
33
#include "openmm/BAOABLangevinIntegrator.h"
34
#include "openmm/BrownianIntegrator.h"
35
36
#include "openmm/CMAPTorsionForce.h"
#include "openmm/CMMotionRemover.h"
37
#include "openmm/CompoundIntegrator.h"
38
39
#include "openmm/CustomAngleForce.h"
#include "openmm/CustomBondForce.h"
40
#include "openmm/CustomCentroidBondForce.h"
41
#include "openmm/CustomCompoundBondForce.h"
42
#include "openmm/CustomCVForce.h"
43
#include "openmm/CustomExternalForce.h"
44
45
#include "openmm/CustomGBForce.h"
#include "openmm/CustomHbondForce.h"
46
#include "openmm/CustomIntegrator.h"
47
#include "openmm/CustomManyParticleForce.h"
48
#include "openmm/CustomNonbondedForce.h"
49
#include "openmm/CustomTorsionForce.h"
50
#include "openmm/GayBerneForce.h"
51
#include "openmm/GBSAOBCForce.h"
52
#include "openmm/HarmonicAngleForce.h"
53
#include "openmm/HarmonicBondForce.h"
54
#include "openmm/LangevinIntegrator.h"
55
#include "openmm/MonteCarloAnisotropicBarostat.h"
56
#include "openmm/MonteCarloBarostat.h"
57
#include "openmm/MonteCarloMembraneBarostat.h"
58
#include "openmm/NonbondedForce.h"
59
#include "openmm/NoseHooverIntegrator.h"
60
61
#include "openmm/PeriodicTorsionForce.h"
#include "openmm/RBTorsionForce.h"
62
#include "openmm/RMSDForce.h"
63
#include "openmm/System.h"
64
#include "openmm/TabulatedFunction.h"
65
66
67
68
#include "openmm/VariableLangevinIntegrator.h"
#include "openmm/VariableVerletIntegrator.h"
#include "openmm/VerletIntegrator.h"

69
#include "openmm/serialization/SerializationProxy.h"
70
#include "openmm/serialization/BAOABLangevinIntegratorProxy.h"
71
#include "openmm/serialization/BrownianIntegratorProxy.h"
72
#include "openmm/serialization/AndersenThermostatProxy.h"
73
74
#include "openmm/serialization/CMAPTorsionForceProxy.h"
#include "openmm/serialization/CMMotionRemoverProxy.h"
75
#include "openmm/serialization/CompoundIntegratorProxy.h"
76
77
#include "openmm/serialization/CustomAngleForceProxy.h"
#include "openmm/serialization/CustomBondForceProxy.h"
78
#include "openmm/serialization/CustomCentroidBondForceProxy.h"
79
#include "openmm/serialization/CustomCompoundBondForceProxy.h"
80
#include "openmm/serialization/CustomCVForceProxy.h"
81
#include "openmm/serialization/CustomExternalForceProxy.h"
82
83
#include "openmm/serialization/CustomGBForceProxy.h"
#include "openmm/serialization/CustomHbondForceProxy.h"
84
#include "openmm/serialization/CustomIntegratorProxy.h"
85
#include "openmm/serialization/CustomManyParticleForceProxy.h"
86
#include "openmm/serialization/CustomNonbondedForceProxy.h"
87
#include "openmm/serialization/CustomTorsionForceProxy.h"
88
#include "openmm/serialization/GayBerneForceProxy.h"
89
#include "openmm/serialization/GBSAOBCForceProxy.h"
90
91
#include "openmm/serialization/HarmonicAngleForceProxy.h"
#include "openmm/serialization/HarmonicBondForceProxy.h"
92
#include "openmm/serialization/LangevinIntegratorProxy.h"
93
#include "openmm/serialization/MonteCarloAnisotropicBarostatProxy.h"
94
#include "openmm/serialization/MonteCarloBarostatProxy.h"
95
#include "openmm/serialization/MonteCarloMembraneBarostatProxy.h"
96
#include "openmm/serialization/NonbondedForceProxy.h"
97
#include "openmm/serialization/NoseHooverIntegratorProxy.h"
98
99
#include "openmm/serialization/PeriodicTorsionForceProxy.h"
#include "openmm/serialization/RBTorsionForceProxy.h"
100
#include "openmm/serialization/RMSDForceProxy.h"
101
#include "openmm/serialization/StateProxy.h"
102
103
#include "openmm/serialization/SystemProxy.h"
#include "openmm/serialization/TabulatedFunctionProxies.h"
104
105
106
#include "openmm/serialization/VariableLangevinIntegratorProxy.h"
#include "openmm/serialization/VariableVerletIntegratorProxy.h"
#include "openmm/serialization/VerletIntegratorProxy.h"
107
108
109

#if defined(WIN32)
    #include <windows.h>
110
    extern "C" void registerSerializationProxies();
111
112
113
114
115
116
117
118
119
120
121
122
    BOOL WINAPI DllMain(HANDLE hModule, DWORD  ul_reason_for_call, LPVOID lpReserved) {
        if (ul_reason_for_call == DLL_PROCESS_ATTACH)
            registerSerializationProxies();
        return TRUE;
    }
#else
    extern "C" void __attribute__((constructor)) registerSerializationProxies();
#endif

using namespace OpenMM;

extern "C" void registerSerializationProxies() {
123
    SerializationProxy::registerProxy(typeid(AndersenThermostat), new AndersenThermostatProxy());
124
    SerializationProxy::registerProxy(typeid(BAOABLangevinIntegrator), new BAOABLangevinIntegratorProxy());
125
    SerializationProxy::registerProxy(typeid(BrownianIntegrator), new BrownianIntegratorProxy());
126
127
    SerializationProxy::registerProxy(typeid(CMAPTorsionForce), new CMAPTorsionForceProxy());
    SerializationProxy::registerProxy(typeid(CMMotionRemover), new CMMotionRemoverProxy());
128
    SerializationProxy::registerProxy(typeid(CompoundIntegrator), new CompoundIntegratorProxy());
129
130
131
    SerializationProxy::registerProxy(typeid(Continuous1DFunction), new Continuous1DFunctionProxy());
    SerializationProxy::registerProxy(typeid(Continuous2DFunction), new Continuous2DFunctionProxy());
    SerializationProxy::registerProxy(typeid(Continuous3DFunction), new Continuous3DFunctionProxy());
132
133
    SerializationProxy::registerProxy(typeid(CustomAngleForce), new CustomAngleForceProxy());
    SerializationProxy::registerProxy(typeid(CustomBondForce), new CustomBondForceProxy());
134
    SerializationProxy::registerProxy(typeid(CustomCentroidBondForce), new CustomCentroidBondForceProxy());
135
    SerializationProxy::registerProxy(typeid(CustomCompoundBondForce), new CustomCompoundBondForceProxy());
136
    SerializationProxy::registerProxy(typeid(CustomCVForce), new CustomCVForceProxy());
137
    SerializationProxy::registerProxy(typeid(CustomExternalForce), new CustomExternalForceProxy());
138
139
    SerializationProxy::registerProxy(typeid(CustomGBForce), new CustomGBForceProxy());
    SerializationProxy::registerProxy(typeid(CustomHbondForce), new CustomHbondForceProxy());
140
    SerializationProxy::registerProxy(typeid(CustomIntegrator), new CustomIntegratorProxy());
141
    SerializationProxy::registerProxy(typeid(CustomManyParticleForce), new CustomManyParticleForceProxy());
142
    SerializationProxy::registerProxy(typeid(CustomNonbondedForce), new CustomNonbondedForceProxy());
143
    SerializationProxy::registerProxy(typeid(CustomTorsionForce), new CustomTorsionForceProxy());
144
145
146
    SerializationProxy::registerProxy(typeid(Discrete1DFunction), new Discrete1DFunctionProxy());
    SerializationProxy::registerProxy(typeid(Discrete2DFunction), new Discrete2DFunctionProxy());
    SerializationProxy::registerProxy(typeid(Discrete3DFunction), new Discrete3DFunctionProxy());
147
    SerializationProxy::registerProxy(typeid(GayBerneForce), new GayBerneForceProxy());
148
    SerializationProxy::registerProxy(typeid(GBSAOBCForce), new GBSAOBCForceProxy());
149
150
    SerializationProxy::registerProxy(typeid(HarmonicAngleForce), new HarmonicAngleForceProxy());
    SerializationProxy::registerProxy(typeid(HarmonicBondForce), new HarmonicBondForceProxy());
151
    SerializationProxy::registerProxy(typeid(LangevinIntegrator), new LangevinIntegratorProxy());
152
    SerializationProxy::registerProxy(typeid(MonteCarloAnisotropicBarostat), new MonteCarloAnisotropicBarostatProxy());
153
    SerializationProxy::registerProxy(typeid(MonteCarloBarostat), new MonteCarloBarostatProxy());
154
    SerializationProxy::registerProxy(typeid(MonteCarloMembraneBarostat), new MonteCarloMembraneBarostatProxy());
155
    SerializationProxy::registerProxy(typeid(NonbondedForce), new NonbondedForceProxy());
156
    SerializationProxy::registerProxy(typeid(NoseHooverIntegrator), new NoseHooverIntegratorProxy());
157
158
    SerializationProxy::registerProxy(typeid(PeriodicTorsionForce), new PeriodicTorsionForceProxy());
    SerializationProxy::registerProxy(typeid(RBTorsionForce), new RBTorsionForceProxy());
159
    SerializationProxy::registerProxy(typeid(RMSDForce), new RMSDForceProxy());
160
    SerializationProxy::registerProxy(typeid(System), new SystemProxy());
161
    SerializationProxy::registerProxy(typeid(State), new StateProxy());
162
163
164
    SerializationProxy::registerProxy(typeid(VariableLangevinIntegrator), new VariableLangevinIntegratorProxy());
    SerializationProxy::registerProxy(typeid(VariableVerletIntegrator), new VariableVerletIntegratorProxy());
    SerializationProxy::registerProxy(typeid(VerletIntegrator), new VerletIntegratorProxy());
165
}