
.. include:: ../substitutions

.. oe:namespace:: OEBio

.. meta::
   :keywords: OEGetResidueAtoms

.. oe:function:: OEGetResidueAtoms

   These two functions generate an iterator of all of the atoms in a
   residue. They differ dramatically in the manner in which the
   residue is specified. In both functions, the assume argument is a
   bitmask that indicates whether the algorithm can assume that the
   molecule has perceived residues, has PDB ordered atoms, or as
   bonded residues (see the :oe:constns:`OEBio::OEAssumption` namespace for more
   information). Please see :ref:`OEHierView <OEBio_OEHierView>` for an additional method for
   accessing the atoms of a residue in a protein.

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

      .. oe:api::

         OESystem::OEIterBase<OEChem::OEAtomBase>* OEGetResidueAtoms(OEChem::OEAtomBase* atom,
                                                                     unsigned assume = OEAssumption::Default)
         OESystem::OEIterBase<const OEChem::OEAtomBase>* OEGetResidueAtoms(const OEChem::OEAtomBase* atom,
                                                                           unsigned assume = OEAssumption::Default)

   .. oe:language:: python

      .. oe:api:: python

         OEGetResidueAtoms(atom: OEAtomBase, assume: int) -> OEAtomIter


   In this function, the residue of interest is identified by passing
   any atom from that residue into the function.

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

      .. oe:api::

         OESystem::OEIterBase<OEChem::OEAtomBase>* OEGetResidueAtoms(OEChem::OEMolBase& mol,
                                                                     const OEChem::OEResidue& residue,
                                                                     unsigned assume = OEAssumption::Default)
         OESystem::OEIterBase<const OEChem::OEAtomBase>* OEGetResidueAtoms(const OEChem::OEMolBase& mol,
                                                                           const OEChem::OEResidue& residue,
                                                                           unsigned assume = OEAssumption::Default)

   .. oe:language:: python

      .. oe:api:: python

         OEGetResidueAtoms(mol: Union[OEGraphMol,OEMol,OEQMol],
                           residue: OEResidue, assume: int) -> OEAtomIter

   In this function, the residue is indicated by a combination of the
   molecule of interest as well as any one of the :ref:`OEResidue <OEChem_OEResidue>`
   objects from the residue.

   .. seealso::

      * :oe:func:`OEBio::OEGetResidueAtom` function
