9 #ifndef IMPRMF_ASSOCIATIONS_H
10 #define IMPRMF_ASSOCIATIONS_H
12 #include <IMP/rmf/rmf_config.h>
18 #include <RMF/names.h>
20 IMPRMF_BEGIN_NAMESPACE
22 typedef base::Object *AssociationType;
24 IMPRMFEXPORT
void set_association(RMF::NodeConstHandle nh, base::Object *o,
25 bool overwrite =
false);
28 inline T *get_association(RMF::NodeConstHandle nh) {
29 AssociationType o = nh.get_association<AssociationType>();
31 if (!op)
return nullptr;
32 return dynamic_cast<T *
>(op);
41 IMPRMFEXPORT RMF::NodeConstHandle get_node_from_association(
42 RMF::FileConstHandle nh, base::Object *oi);
44 IMPRMFEXPORT RMF::NodeHandle get_node_from_association(RMF::FileHandle nh,
46 IMPRMFEXPORT
bool get_has_associated_node(RMF::FileConstHandle nh,
Various general useful macros for IMP.
Handle read/write of kernel::Model data from/to files.
Logging and error reporting support.
A nullptr-initialized pointer to an IMP Object.
A shared base class to help in debugging and things.