IMP  2.3.0
The Integrative Modeling Platform
InContainerQuadFilter.h
Go to the documentation of this file.
1 /**
2  * \file IMP/container/InContainerQuadFilter.h
3  * \brief A filter for Quads.
4  *
5  * This file is generated by a script (core/tools/make-containers).
6  * Do not edit directly.
7  *
8  * Copyright 2007-2014 IMP Inventors. All rights reserved.
9  */
10 
11 #ifndef IMPCONTAINER_IN_CONTAINER_QUAD_FILTER_H
12 #define IMPCONTAINER_IN_CONTAINER_QUAD_FILTER_H
13 
14 #include <IMP/container/container_config.h>
15 #include <IMP/QuadPredicate.h>
16 #include <IMP/QuadContainer.h>
17 #include <IMP/kernel/internal/container_helpers.h>
18 #include "internal/QuadContainerIndex.h"
19 #include <IMP/quad_macros.h>
20 #include <IMP/base/object_macros.h>
22 
23 IMPCONTAINER_BEGIN_NAMESPACE
24 
25 //! A filter which returns true if a container containers the Quad
26 /** This predicate returns 1 if the passed tuple is in the container.
27  \note Use the handle_permutations parameter to the constructor to
28  determine whether only exact matchers, or matches under permutation
29  are considered matching. By default they are are.
30  */
31 class IMPCONTAINEREXPORT InContainerQuadFilter
32  : public QuadPredicate {
34 
35  public:
37  std::string name = "QuadFilter %1%");
38  InContainerQuadFilter(QuadContainer *c, bool handle_permutations,
39  std::string name = "QuadFilter %1%");
40 
42  IMP_OVERRIDE {
43  return c_->get_contains(vt);
44  }
48  ret.push_back(c_);
49  return ret;
50  }
53 };
54 
56 
57 IMPCONTAINER_END_NAMESPACE
58 
59 #endif /* IMPCONTAINER_IN_CONTAINER_QUAD_FILTER_H */
Various general useful macros for IMP.
Import IMP/kernel/QuadPredicate.h in the namespace.
A shared container for Quads.
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Definition: object_macros.h:25
virtual int get_value_index(kernel::Model *, const kernel::ParticleIndexQuad &vt) const
Compute the predicate and the derivative if needed.
ParticlesTemp get_particles(kernel::Model *m, const ParticleIndexes &ps)
A filter which returns true if a container containers the Quad.
Import IMP/kernel/quad_macros.h in the namespace.
Import IMP/kernel/QuadContainer.h in the namespace.
Abstract predicate function.
A class to store an fixed array of same-typed values.
Definition: Array.h:33
Various general useful macros for IMP.
virtual kernel::ModelObjectsTemp do_get_inputs(kernel::Model *m, const kernel::ParticleIndexes &pi) const
#define IMP_QUAD_PREDICATE_METHODS(Name)
Define extra the functions needed for a QuadPredicate.
#define IMP_OBJECTS(Name, PluralName)
Define the types for storing sets of objects.
Definition: object_macros.h:52
#define IMP_OVERRIDE
Cause a compile error if this method does not override a parent method.
Class for storing model, its restraints, constraints, and particles.
Definition: kernel/Model.h:73