IMP
2.1.0
The Integrative Modeling Platform
IMP Mainpage
All IMP Modules
Related Pages
Modules
Namespaces
Classes
Files
Examples
Indexes
File List
File Members
ExampleConstraint.h
Go to the documentation of this file.
1
/**
2
* \file IMP/example/ExampleConstraint.h
3
* \brief A restraint on a list of particle pairs.
4
*
5
* Copyright 2007-2013 IMP Inventors. All rights reserved.
6
*
7
*/
8
9
#ifndef IMPEXAMPLE_EXAMPLE_CONSTRAINT_H
10
#define IMPEXAMPLE_EXAMPLE_CONSTRAINT_H
11
12
#include <IMP/example/example_config.h>
13
#include <
IMP/SingletonScore.h
>
14
#include <
IMP/Constraint.h
>
15
#include <
IMP/PairContainer.h
>
16
#include <
IMP/PairScore.h
>
17
#include <
IMP/score_state_macros.h
>
18
19
IMPEXAMPLE_BEGIN_NAMESPACE
20
21
//! A trivial constraint that just increments a counter
22
/**
23
*/
24
class
IMPEXAMPLEEXPORT
ExampleConstraint
:
public
Constraint
{
25
base::Pointer<kernel::Particle>
p_;
26
IntKey
k_;
27
28
public
:
29
ExampleConstraint
(
kernel::Particle
*p);
30
31
virtual
void
do_update_attributes() IMP_OVERRIDE;
32
virtual
void
do_update_derivatives(
DerivativeAccumulator
*da) IMP_OVERRIDE;
33
virtual
kernel::ModelObjectsTemp
do_get_inputs
()
const
IMP_OVERRIDE;
34
virtual
kernel::ModelObjectsTemp
do_get_outputs
()
const
IMP_OVERRIDE;
35
IMP_OBJECT_METHODS
(
ExampleConstraint
);
36
};
37
38
IMPEXAMPLE_END_NAMESPACE
39
40
#endif
/* IMPEXAMPLE_EXAMPLE_CONSTRAINT_H */
IMP::kernel::Key
A base class for Keys.
Definition:
kernel/Key.h:46
IMP::kernel::DerivativeAccumulator
Class for adding derivatives from restraints to the model.
Definition:
kernel/DerivativeAccumulator.h:25
IMP::base::Pointer
A smart pointer to a reference counted object.
Definition:
base/Pointer.h:87
IMP::base::Vector
Definition:
base/Vector.h:37
PairContainer.h
Import IMP/kernel/PairContainer.h in the namespace.
PairScore.h
Import IMP/kernel/PairScore.h in the namespace.
IMP_OBJECT_METHODS
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Definition:
base/object_macros.h:25
Constraint.h
Import IMP/kernel/Constraint.h in the namespace.
IMP::kernel::Particle
Class to handle individual model particles.
Definition:
kernel/declare_Particle.h:34
SingletonScore.h
Import IMP/kernel/SingletonScore.h in the namespace.
score_state_macros.h
Import IMP/kernel/score_state_macros.h in the namespace.
IMP::kernel::ModelObject::do_get_inputs
virtual ModelObjectsTemp do_get_inputs() const =0
IMP::kernel::Constraint
Implement a constraint on the Model.
Definition:
kernel/Constraint.h:48
IMP::example::ExampleConstraint
A trivial constraint that just increments a counter.
Definition:
ExampleConstraint.h:24
IMP::kernel::ModelObject::do_get_outputs
virtual ModelObjectsTemp do_get_outputs() const =0