.. include:: ../substitutions

.. oe:namespace:: OEChem

.. meta::
   :keywords: OEGetResidueName

.. oe:function:: OEGetResidueName

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

      .. oe:api::

         const char* OEGetResidueName(unsigned int idx)

   .. oe:language:: python

      .. oe:api:: python

         OEGetResidueName(idx: int) -> str

   Converts an **OEChem TK** residue index, as returned by the
   :oe:func:`OEChem::OEGetResidueIndex` function, back into a
   three-character string representation.  Valid indices are specified in
   **OEChemTK**'s :oe:constns:`OEChem::OEResidueIndex` namespace.

   A NULL pointer, ``(char*)0``, is returned for invalid or unrecognized
   argument values.  All other returned string constants are guaranteed
   to be three characters long.  For example, the input value
   :oe:const:`OEChem::OEResidueIndex::ALA` returns the string value
   ``"ALA"``.
