
.. include:: ../substitutions

.. oe:namespace:: OEChem

.. meta::
   :keywords: OEFindRingAtomsAndBonds

..  _OEFindRingAtomsAndBonds:

.. oe:function:: OEFindRingAtomsAndBonds

   .. oe:language:: c++ java csharp

      .. oe:api::

         void OEFindRingAtomsAndBonds(OEMolBase& mol)

   .. oe:language:: python

      .. oe:api:: python

         OEFindRingAtomsAndBonds(mol: Union[OEGraphMol,OEMol,OEQMol]) -> None

   Determines which atoms and bonds of a molecule are contained in rings,
   and set their 'in ring' property appropriately via
   :oe:meth:`OEChem::OEAtomBase::SetInRing` and
   :oe:meth:`OEChem::OEBondBase::SetInRing` methods, respectively.

   .. seealso::

      * :ref:`chapter_ring` chapter
      * :ref:`chapter_connectivity` chapter and :ref:`section_connectivity_bond_order_perception` section

      .. oe:language:: c++

         * Example program :ref:`cansmi.cpp<section_example_oechem_cansmi>`

      .. oe:language:: python

         * Example program :ref:`cansmi.py<section_example_oechem_cansmi>`

      .. oe:language:: java

         * Example program :ref:`CanSmi.java<section_example_oechem_cansmi>`

      .. oe:language:: csharp

         * Example program :ref:`CanSmi.cs<section_example_oechem_cansmi>`
