<- Back | Index | Forward ->

Member Functions

Most toolkit functions have simple mappings to object methods.
  mol.cansmiles(1)  -->  dt_cansmiles(mol.handle, 1)

  atom1.addbond(atom2, bondtype) -->
           dt_addbond(atom1.handle, atom2.handle, bondtype)

Python objects must store the handle of the underlying toolkit object

Not everything has a natural mapping. Consider "dt_xatom."
Which is better?

   other_atom = bond.xatom(atom)
   other_atom = atom.xatom(bond)
I couldn't decide, so we support both forms.