"platforms/cuda/tests/TestCudaRGForce.cpp" did not exist on "15811b7c56b65a5e94e4c7b212100b37b4de331f"
Commit 407c0b93 authored by Peter Eastman's avatar Peter Eastman
Browse files

Moved some code from header to cpp file to avoid an error generating the C wrappers

parent 0c96184b
......@@ -37,7 +37,6 @@
#include <map>
#include <vector>
#include "internal/windowsExport.h"
#include "internal/ContextImpl.h"
namespace OpenMM {
......@@ -54,18 +53,8 @@ class ContextImpl;
class OPENMM_EXPORT Integrator {
public:
Integrator() : owner(NULL), context(NULL) {
}
virtual ~Integrator() {
if (context != NULL) {
// The Integrator is being deleted before the Context, so do cleanup now,
// then notify the ContextImpl so its own destructor won't try to clean up
// the (no longer existing) Integrator.
cleanup();
context->integratorDeleted();
}
}
Integrator();
virtual ~Integrator();
/**
* Get the size of each time step, in picoseconds. If this integrator uses variable time steps,
* the size of the most recent step is returned.
......
/* -------------------------------------------------------------------------- *
* 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. *
* *
* Portions copyright (c) 2013 Stanford University and the Authors. *
* 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. *
* -------------------------------------------------------------------------- */
#include "openmm/Integrator.h"
#include "openmm/internal/ContextImpl.h"
using namespace OpenMM;
Integrator::Integrator() : owner(NULL), context(NULL) {
}
Integrator::~Integrator() {
if (context != NULL) {
// The Integrator is being deleted before the Context, so do cleanup now,
// then notify the ContextImpl so its own destructor won't try to clean up
// the (no longer existing) Integrator.
cleanup();
context->integratorDeleted();
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment