9 #ifndef IMPRMF_HIERARCHY_SAVE_LINK_H
10 #define IMPRMF_HIERARCHY_SAVE_LINK_H
12 #include <IMP/rmf/rmf_config.h>
14 #include "internal/atom_links_static.h"
15 #include "internal/atom_links_rigid_bodies.h"
16 #include "internal/atom_links_xyzs.h"
17 #include "internal/atom_links_gaussians.h"
18 #include <RMF/decorator/alternatives.h>
19 #include <RMF/decorator/provenance.h>
22 #include <RMF/NodeHandle.h>
23 #include <RMF/FileHandle.h>
29 #include <RMF/decorators.h>
30 #include <boost/unordered_map.hpp>
33 IMPRMF_BEGIN_NAMESPACE
42 internal::HierarchySaveStatic save_static;
43 internal::HierarchySaveBonds save_bonds;
44 internal::HierarchySaveXYZs save_xyzs;
45 internal::HierarchySaveGaussians save_gaussians;
46 internal::HierarchySaveRigidBodies save_rigid_bodies;
47 Data(RMF::FileHandle h)
52 save_rigid_bodies(h) {}
54 typedef boost::unordered_map<ParticleIndex, std::shared_ptr<Data> >
57 RMF::decorator::AlternativesFactory af_;
58 RMF::decorator::StructureProvenanceFactory strucpf_;
59 RMF::decorator::SampleProvenanceFactory samppf_;
60 RMF::decorator::CombineProvenanceFactory combpf_;
61 RMF::decorator::FilterProvenanceFactory filtpf_;
62 RMF::decorator::ClusterProvenanceFactory clustpf_;
63 RMF::decorator::ScriptProvenanceFactory scriptpf_;
64 RMF::decorator::SoftwareProvenanceFactory softpf_;
65 RMF::decorator::ExplicitResolutionFactory explicit_resolution_factory_;
76 virtual void do_add(
Particle *p, RMF::NodeHandle cur)
override;
77 virtual void do_save_one(
Particle *o,
78 RMF::NodeHandle nh)
override;
79 RMF::NodeType get_type(
Particle *)
const override {
80 return RMF::REPRESENTATION;
94 RMF::NodeHandle root_node) {
102 static const char *get_name() {
return "atom save"; }
Helper macros for implementing IMP Objects.
Classes to track how the model was created.
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
virtual void do_save_hierarchy(Model *m, ParticleIndex root, RMF::NodeHandle root_node)
Macros to help in defining tuple classes.
Class for storing model, its restraints, constraints, and particles.
Decorator for helping deal with a hierarchy of molecules.
#define IMP_UNUSED(variable)
Manage links between IMP objects and a part of the RMF file.
Various general useful macros for IMP.
Key< 1 > IntKey
The type used to identify int attributes in the Particles.
macros for display classes
Manage links between IMP objects and RMF nodes.
Class to handle individual particles of a Model object.
void add_provenance(Model *m, ParticleIndex pi, Provenance p)
Add provenance to part of the model.
virtual void do_setup_node(Model *m, ParticleIndex root, ParticleIndex p, RMF::NodeHandle n)