IMP  2.0.1
The Integrative Modeling Platform
PairRestraint.h
Go to the documentation of this file.
1 /**
2  * \file IMP/core/PairRestraint.h
3  * \brief Apply a PairScore to a Pair.
4  *
5  * WARNING This file was generated from PairRestraint.h
6  * in /tmp/nightly-build-36540/imp-2.0.1/tools/build/container_templates/core
7  * by tools/maintenance/setup_containers.py.
8  *
9  * Copyright 2007-2013 IMP Inventors. All rights reserved.
10  *
11  */
12 
13 #ifndef IMPCORE_PAIR_RESTRAINT_H
14 #define IMPCORE_PAIR_RESTRAINT_H
15 
16 #include <IMP/core/core_config.h>
17 
18 #include <IMP/internal/TupleRestraint.h>
19 #include <IMP/PairScore.h>
20 #include <IMP/restraint_macros.h>
21 
22 #include <iostream>
23 
24 IMPCORE_BEGIN_NAMESPACE
25 
26 //! Applies a PairScore to a Pair.
27 /** This restraint stores a Pair.
28  \see PairRestraint
29  */
31 #if defined(SWIG) || defined(IMP_DOXYGEN)
32  public Restraint
33 #else
34  public IMP::kernel::internal::TupleRestraint<PairScore>
35 #endif
36 {
37 public:
38  //! Create the restraint.
39  /** This function takes the function to apply to the
40  stored Pair and the Pair.
41  */
43  const ParticlePair& vt,
44  std::string name="PairRestraint %1%"):
45  IMP::kernel::internal::TupleRestraint<PairScore>(ss,
46  IMP::kernel::internal::get_model(vt),
47  IMP::kernel::internal::get_index(vt),
48  name)
49  {}
50 
51 #if defined(SWIG) || defined(IMP_DOXYGEN)
52  protected:
53  double unprotected_evaluate(IMP::DerivativeAccumulator *accum) const;
54  IMP::ModelObjectsTemp do_get_inputs() const;
56 #endif
57 };
58 
59 IMPCORE_END_NAMESPACE
60 
61 #endif /* IMPCORE_PAIR_RESTRAINT_H */