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 Object *AssociationType;
24 IMPRMFEXPORT
void set_association(RMF::NodeConstHandle nh, 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, 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.
Manage links between IMP objects and a part of the RMF file.
Logging and error reporting support.
A nullptr-initialized pointer to an IMP Object.
A shared base class to help in debugging and things.