.. include:: ../substitutions

.. oe:namespace:: OEChem

.. meta::
   :keywords: OEMDLGetParity

.. oe:function:: OEMDLGetParity

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

      .. oe:api::

         bool OEMDLGetParity(const OEMolBase& mol)
         bool OEMDLGetParity(const OEMCMolBase& mol)

   .. oe:language:: python

      .. oe:api:: python

         OEMDLGetParity(mol: Union[OEGraphMol,OEQMol]) -> bool

   Returns the MDL 'chiral' flag status for a molecule.  After reading from an
   MDL connection table this value is ``true`` if the chiral flag was 'on' in
   the header, indicating absolute stereochemistry for marked stereocenters.
   This value is ``false`` if the chiral flag setting was 'off' in the header,
   indicating relative stereochemistry for marked stereocenters. After calling the
   :oe:func:`OEChem::OEMDLPerceiveParity` function this value is forced to ``true``
   if any non-zero atom stereo parity values have been assigned.  The function
   :oe:func:`OEChem::OEMDLHasParity` returns whether the 'chiral' flag status is
   available, which may indicate the structure originated from an MDL structure file.
   If :oe:func:`OEChem::OEMDLHasParity` is ``false``, this function will also
   return ``false`` by default.

   The :ref:`OEMCMolBase <OEChem_OEMCMolBase>` overload of this function returns the 'chiral' flag status
   of the **active** conformer in the multi-conformer molecule.

   .. seealso::

      * :oe:func:`OEChem::OEMDLPerceiveParity` function
      * :oe:func:`OEChem::OEMDLHasParity` and :oe:func:`OEChem::OEMDLSetParity` functions
      * :oe:func:`OEChem::OEMDLClearParity` function
