IMP  2.3.1
The Integrative Modeling Platform
QuadContainerSet.h
Go to the documentation of this file.
1 /**
2  * \file IMP/container/QuadContainerSet.h
3  * \brief Store a set of QuadContainers
4  *
5  * This file is generated by a script (tools/maintenance/make-container).
6  * Do not edit directly.
7  *
8  * Copyright 2007-2014 IMP Inventors. All rights reserved.
9  */
10 
11 #ifndef IMPCONTAINER_QUAD_CONTAINER_SET_H
12 #define IMPCONTAINER_QUAD_CONTAINER_SET_H
13 
14 #include <IMP/container/container_config.h>
15 #include <IMP/QuadContainer.h>
16 #include <IMP/container_macros.h>
17 #include <IMP/kernel/internal/container_helpers.h>
18 #include <IMP/scoped.h>
19 
20 IMPCONTAINER_BEGIN_NAMESPACE
21 
22 //! Stores a set of QuadContainers
23 /** The input sets must be disjoint. This can change if there is
24  demand for it.
25 
26  \usesconstraint
27 */
28 class IMPCONTAINEREXPORT QuadContainerSet : public QuadContainer {
29  Ints versions_;
30  static QuadContainerSet *get_set(QuadContainer *c) {
31  return dynamic_cast<QuadContainerSet *>(c);
32  }
33  virtual std::size_t do_get_contents_hash() const IMP_OVERRIDE;
34 
35  public:
36  //! Construct and empty set
38  std::string name = "QuadContainerSet %1%");
39 
41  std::string name = "QuadContainerSet %1%");
42 
43  /** \brief apply modifer sm to all quad containers */
44  IMP_IMPLEMENT(void do_apply(const QuadModifier *sm) const);
45 
46  template <class M>
47  void apply_generic(const M *m) const {
48  apply(m);
49  }
50 
53 
54  /** @name Methods to control the nested container
55 
56  This container merges a set of nested containers. To add
57  or remove nested containers, use the methods below.
58  */
59  /**@{*/
60  IMP_LIST_ACTION(public, QuadContainer, QuadContainers,
61  quad_container, quad_containers,
63  {
64  obj->set_was_used(true);
65  versions_.clear();
66  },
67  {}, );
68 /**@}*/
69 
70 #ifndef IMP_DOXYGEN
74 #endif
75 };
76 
77 IMPCONTAINER_END_NAMESPACE
78 
79 #endif /* IMPCONTAINER_QUAD_CONTAINER_SET_H */
Import IMP/kernel/scoped.h in the namespace.
virtual ParticleIndexes get_all_possible_indexes() const =0
Get contained particles.
virtual kernel::ParticleIndexQuads get_indexes() const =0
A shared container for Quads.
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Definition: object_macros.h:25
Import IMP/kernel/QuadContainer.h in the namespace.
IMP::base::Vector< IMP::base::Pointer< QuadContainer > > QuadContainers
void apply(const QuadModifier *sm) const
Apply a SingletonModifier to the contents.
#define IMP_IMPLEMENT(signature)
Stores a set of QuadContainers.
Import IMP/kernel/container_macros.h in the namespace.
IMP::base::Vector< IMP::base::WeakPointer< QuadContainer > > QuadContainersTemp
void apply_generic(const M *m) const
apply modifer sm to all quad containers
virtual ModelObjectsTemp do_get_inputs() const =0
virtual kernel::ParticleIndexQuads get_range_indexes() const =0
A base class for modifiers of kernel::ParticleQuadsTemp.
#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