.. include:: ../substitutions

.. oe:namespace:: OEChem

.. meta::
   :keywords: OETheFunctionFormerlyKnownAsStripSalts

.. oe:function:: OETheFunctionFormerlyKnownAsStripSalts

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

      .. oe:api::

         bool OETheFunctionFormerlyKnownAsStripSalts(OEMolBase& mol)

   .. oe:language:: python

      .. oe:api:: python

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

   Deletes all atoms that are not part of the largest connected component
   of a molecule.  If two or more components of a molecule are the size
   of the largest component, this function keeps the first one
   encountered.

.. note::

   The :oe:func:`OEChem::OETheFunctionFormerlyKnownAsStripSalts` function is
   identical to :oe:func:`OEChem::OEDeleteEverythingExceptTheFirstLargestComponent`.

.. seealso::

  .. oe:language:: c++

      * Example program :ref:`stripsalts.cpp<section_example_oechem_stripsalts>`

  .. oe:language:: python

      * Example program :ref:`stripsalts.py<section_example_oechem_stripsalts>`

  .. oe:language:: java

      * Example program :ref:`StripSalts.java<section_example_oechem_stripsalts>`

  .. oe:language:: csharp

      * Example program :ref:`StripSalts.cs<section_example_oechem_stripsalts>`
