00001 // 00002 // Copyright (C) 2002-2008 Greg Landrum and Rational Discovery LLC 00003 // 00004 // @@ All Rights Reserved @@ 00005 // 00006 #ifndef _RD_SMILESWRITE_H 00007 #define _RD_SMILESWRITE_H 00008 00009 #include <string> 00010 00011 00012 namespace RDKit{ 00013 class Atom; 00014 class Bond; 00015 class ROMol; 00016 namespace SmilesWrite { 00017 //! \brief returns true if the atom number is in the SMILES organic subset 00018 bool inOrganicSubset(int atomicNumber); 00019 00020 //! \brief returns the SMILES for an atom 00021 /*! 00022 \param atom : the atom to work with 00023 \param doKekule : we're doing kekulized smiles (e.g. don't use 00024 lower case for the atom label) 00025 \param bondIn : the bond we came into the atom on (used for 00026 chirality calculation 00027 */ 00028 std::string GetAtomSmiles(const Atom *atom,bool doKekule=false, 00029 const Bond *bondIn=0); 00030 00031 //! \brief returns the SMILES for a bond 00032 /*! 00033 \param bond : the bond to work with 00034 \param atomToLeftIdx : the index of the atom preceding \c bond 00035 in the SMILES 00036 \param doKekule : we're doing kekulized smiles (e.g. write out 00037 bond orders for aromatic bonds) 00038 */ 00039 std::string GetBondSmiles(const Bond *bond,int atomToLeftIdx=-1, 00040 bool doKekule=false); 00041 } 00042 00043 //! \brief returns canonical SMILES for a molecule 00044 /*! 00045 \param mol : the molecule in question. NOTE that the molecule may 00046 be modified as part of the canonicalization process. 00047 \param doIsomericSmiles : include stereochemistry and isotope information 00048 in the SMILES 00049 \param doKekule : do Kekule smiles (i.e. don't use aromatic bonds) 00050 \param rootedAtAtom : make sure the SMILES starts at the specified atom. 00051 The resulting SMILES is not, of course, canonical. 00052 */ 00053 std::string MolToSmiles(ROMol &mol,bool doIsomericSmiles=false, 00054 bool doKekule=false,int rootedAtAtom=-1); 00055 } 00056 #endif
1.5.3