 |
RDKit
Open-source cheminformatics and machine learning.
|
Go to the documentation of this file.
17 #ifndef __RD_RWMOL_H__
18 #define __RD_RWMOL_H__
45 RWMol(
const ROMol &other,
bool quickCopy =
false,
int confId = -1)
46 :
ROMol(other, quickCopy, confId) {
47 d_partialBonds.
clear();
53 void insertMol(
const ROMol &other);
66 unsigned int addAtom(
bool updateLabel =
true);
80 bool takeOwnership =
false) {
81 return ROMol::addAtom(atom, updateLabel, takeOwnership);
95 void replaceAtom(
unsigned int idx,
Atom *atom,
bool updateLabel =
false,
96 bool preserveProps =
false);
104 Atom *getActiveAtom();
106 void setActiveAtom(
Atom *atom);
108 void setActiveAtom(
unsigned int idx);
110 void removeAtom(
unsigned int idx);
112 void removeAtom(
Atom *atom);
123 unsigned int addBond(
unsigned int beginAtomIdx,
unsigned int endAtomIdx,
126 unsigned int addBond(
Atom *beginAtom,
Atom *endAtom,
139 return ROMol::addBond(bond, takeOwnership);
170 Bond *createPartialBond(
unsigned int beginAtomIdx,
178 unsigned int finishPartialBond(
unsigned int endAtomIdx,
int bondBookmark,
182 void removeBond(
unsigned int beginAtomIdx,
unsigned int endAtomIdx);
191 void replaceBond(
unsigned int idx,
Bond *bond,
bool preserveProps =
false);
203 return ROMol::setStereoGroups(std::move(stereo_groups));
215 std::vector<Bond *> d_partialBonds;
RWMol(const RWMol &other)
Defines the primary molecule class ROMol as well as associated typedefs.
class for representing a bond
RWMol is a molecule class that is intended to be edited.
boost::shared_ptr< RWMol > RWMOL_SPTR
The class for representing atoms.
#define RDKIT_GRAPHMOL_EXPORT
Atom * getLastAtom()
returns a pointer to the highest-numbered Atom
unsigned int addAtom(Atom *atom, bool updateLabel=true, bool takeOwnership=false)
adds an Atom to our collection
std::vector< RWMOL_SPTR > RWMOL_SPTR_VECT
void setStereoGroups(std::vector< StereoGroup > &&stereo_groups)
Sets groups of atoms with relative stereochemistry.
unsigned int addBond(Bond *bond, bool takeOwnership=false)
adds a Bond to our collection
RWMol(const ROMol &other, bool quickCopy=false, int confId=-1)
copy constructor with a twist
void clear()
removes all atoms, bonds, properties, bookmarks, etc.