home
about
news
download
doc
source
systems
tests
bugs
contact
IMP Reference Guide
2.14.0
The Integrative Modeling Platform
IMP Manual
Reference Guide
Tutorial Index
Modules
Classes
Examples
include
IMP
core
version 2.14.0
SingletonConstraint.h
Go to the documentation of this file.
1
// Autogenerated by ../../../../tmp/nightly-build-16408/imp-2.14.0/tools/build/make_containers.py
2
// from ../../../../tmp/nightly-build-16408/imp-2.14.0/tools/build/container_templates/core/ClassnameConstraint.h
3
// Do not edit - any changes will be lost!
4
5
/**
6
* \file IMP/core/SingletonConstraint.h
7
* \brief Use a SingletonModifier applied to a ParticlesTemp to
8
* maintain an invariant
9
*
10
* Copyright 2007-2020 IMP Inventors. All rights reserved.
11
*/
12
13
#ifndef IMPCORE_SINGLETON_CONSTRAINT_H
14
#define IMPCORE_SINGLETON_CONSTRAINT_H
15
16
#include <IMP/core/core_config.h>
17
#include <IMP/internal/TupleConstraint.h>
18
#include <
IMP/SingletonModifier.h
>
19
#include <
IMP/SingletonDerivativeModifier.h
>
20
21
IMPCORE_BEGIN_NAMESPACE
22
//! Apply a SingletonFunction to a Singleton
23
/** The score state is passed up to two SingletonModifiers, one to
24
apply before evaluation and the other after. The one after
25
should take a DerivativeAccumulator as its last argument for
26
SingletonModifier::apply() and will only be called if
27
the score was computed with derivatives.
28
29
\see container::SingletonsConstraint
30
*/
31
class
SingletonConstraint
:
32
#if defined(IMP_DOXYGEN) || defined(SWIG)
33
public
Constraint
34
#else
35
public
IMP::internal::TupleConstraint<SingletonModifier,
36
SingletonDerivativeModifier>
37
#endif
38
{
39
public
:
40
/** \deprecated_at{2.1} Use the model/index constructor.
41
*/
42
IMPCORE_DEPRECATED_METHOD_DECL(2.1)
43
SingletonConstraint
(
SingletonModifier
*before,
44
SingletonDerivativeModifier
*after,
Particle
* vt,
45
std::
string
name = "
SingletonConstraint
%1%")
46
: IMP::internal::TupleConstraint<
47
SingletonModifier
,
SingletonDerivativeModifier
>(before, after, vt,
48
name) {
49
IMPCORE_DEPRECATED_METHOD_DEF(2.1,
"Use the model/index constructor."
);
50
}
51
52
SingletonConstraint
(
SingletonModifier
*before,
53
SingletonDerivativeModifier
*after,
Model
*m,
54
ParticleIndex
vt,
55
std::string name =
"SingletonConstraint %1%"
)
56
: IMP::internal::TupleConstraint<
57
SingletonModifier
,
SingletonDerivativeModifier
>(before, after, m,
58
vt, name) {}
59
60
#if defined(IMP_DOXYGEN) || defined(SWIG)
61
protected
:
62
void
do_update_attributes();
63
void
do_update_derivatives(
DerivativeAccumulator
*da);
64
virtual
ModelObjectsTemp
do_get_inputs()
const
;
65
virtual
ModelObjectsTemp
do_get_outputs()
const
;
66
IMP_OBJECT_METHODS
(
SingletonConstraint
);
67
#endif
68
};
69
70
IMPCORE_END_NAMESPACE
71
72
#endif
/* IMPCORE_SINGLETON_CONSTRAINT_H */
IMP::SingletonModifier
A base class for modifiers of ParticlesTemp.
Definition:
SingletonModifier.h:32
SingletonModifier.h
A Modifier on ParticlesTemp.
IMP_OBJECT_METHODS
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Definition:
object_macros.h:25
IMP::Index< ParticleIndexTag >
IMP::core::SingletonConstraint
Apply a SingletonFunction to a Singleton.
Definition:
SingletonConstraint.h:31
IMP::Vector
A more IMP-like version of the std::vector.
Definition:
Vector.h:39
IMP::Constraint
Implement a constraint on the Model.
Definition:
Constraint.h:49
IMP::Model
Class for storing model, its restraints, constraints, and particles.
Definition:
Model.h:72
SingletonDerivativeModifier.h
A Modifier on ParticlesTemp.
IMP::Particle
Class to handle individual particles of a Model object.
Definition:
Particle.h:41
IMP::DerivativeAccumulator
Class for adding derivatives from restraints to the model.
Definition:
DerivativeAccumulator.h:25