![]() |
RDKit
Open-source cheminformatics and machine learning.
|
This class is used to store ROMol objects in a MolCatalog. More...
#include <MolCatalogEntry.h>
Public Member Functions | |
MolCatalogEntry () | |
MolCatalogEntry (const MolCatalogEntry &other) | |
copy constructor More... | |
MolCatalogEntry (const ROMol *omol) | |
create an entry to hold the provided ROMol More... | |
MolCatalogEntry (const std::string &pickle) | |
construct from a pickle More... | |
~MolCatalogEntry () | |
std::string | getDescription () const |
returns a text description of this entry More... | |
void | setDescription (std::string val) |
unsigned int | getOrder () const |
void | setOrder (unsigned int order) |
const ROMol * | getMol () const |
void | setMol (const ROMol *molPtr) |
hold the provided ROMol More... | |
template<typename T > | |
void | setProp (const char *key, T &val) const |
set a named property More... | |
template<typename T > | |
void | setProp (const std::string &key, T &val) const |
template<typename T > | |
void | getProp (const char *key, T &res) const |
get the value of a named property More... | |
template<typename T > | |
void | getProp (const std::string &key, T &res) const |
bool | hasProp (const char *key) const |
returns true if such a property exists More... | |
bool | hasProp (const std::string &key) const |
void | clearProp (const char *key) const |
clears a named property More... | |
void | clearProp (const std::string &key) const |
void | toStream (std::ostream &ss) const |
serializes this entry to the stream More... | |
std::string | Serialize () const |
returns a serialized (pickled) form of the entry More... | |
void | initFromStream (std::istream &ss) |
initialize from a stream containing a pickle More... | |
void | initFromString (const std::string &text) |
initialize from a string containing a pickle More... | |
![]() | |
virtual | ~CatalogEntry ()=0 |
void | setBitId (int bid) |
sets our bit Id More... | |
int | getBitId () const |
returns our bit Id More... | |
This class is used to store ROMol objects in a MolCatalog.
Definition at line 16 of file MolCatalogEntry.h.
|
inline |
Definition at line 18 of file MolCatalogEntry.h.
References RDCatalog::CatalogEntry::setBitId().
RDKit::MolCatalogEntry::MolCatalogEntry | ( | const MolCatalogEntry & | other | ) |
copy constructor
RDKit::MolCatalogEntry::MolCatalogEntry | ( | const ROMol * | omol | ) |
create an entry to hold the provided ROMol
The MolCatalogEntry takes ownership of the pointer
|
inline |
construct from a pickle
Definition at line 33 of file MolCatalogEntry.h.
References initFromString(), and ~MolCatalogEntry().
RDKit::MolCatalogEntry::~MolCatalogEntry | ( | ) |
Referenced by MolCatalogEntry().
|
inline |
clears a named property
Definition at line 84 of file MolCatalogEntry.h.
References RDKit::Dict::clearVal().
|
inline |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 86 of file MolCatalogEntry.h.
References clearProp(), initFromStream(), initFromString(), Serialize(), and toStream().
Referenced by clearProp().
|
inlinevirtual |
returns a text description of this entry
Implements RDCatalog::CatalogEntry.
Definition at line 37 of file MolCatalogEntry.h.
|
inline |
Definition at line 44 of file MolCatalogEntry.h.
References setMol().
|
inline |
Definition at line 41 of file MolCatalogEntry.h.
|
inline |
get the value of a named property
Definition at line 66 of file MolCatalogEntry.h.
References RDKit::Dict::getVal().
Referenced by getProp().
|
inline |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 71 of file MolCatalogEntry.h.
References getProp().
|
inline |
returns true if such a property exists
Definition at line 76 of file MolCatalogEntry.h.
References RDKit::Dict::hasVal().
|
inline |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 81 of file MolCatalogEntry.h.
References hasProp().
Referenced by hasProp().
|
virtual |
initialize from a stream containing a pickle
Implements RDCatalog::CatalogEntry.
Referenced by clearProp().
|
virtual |
initialize from a string containing a pickle
Implements RDCatalog::CatalogEntry.
Referenced by clearProp(), and MolCatalogEntry().
|
virtual |
returns a serialized (pickled) form of the entry
Implements RDCatalog::CatalogEntry.
Referenced by clearProp().
|
inline |
Definition at line 39 of file MolCatalogEntry.h.
void RDKit::MolCatalogEntry::setMol | ( | const ROMol * | molPtr | ) |
hold the provided ROMol
The MolCatalogEntry takes ownership of the pointer. If the MolCatalogEntry already has a molecule, this one will be deleted.
Referenced by getMol().
|
inline |
Definition at line 42 of file MolCatalogEntry.h.
|
inline |
set a named property
Definition at line 54 of file MolCatalogEntry.h.
References RDKit::Dict::setVal().
Referenced by setProp().
|
inline |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 60 of file MolCatalogEntry.h.
References setProp().
|
virtual |