.. include:: ../../toolkit-substitutions

.. oe:namespace:: OEOpt



.. meta::
   :keywords: OEFComponent, FComponent


.. _OEOpt_OEFComponent:

.. oe:class:: OEFComponent

   .. attention::

      |TWOLANGUAGE|

   .. oe:api::


      struct OEFComponent

   The :ref:`OEFComponent <OEOpt_OEFComponent>` class associates interaction-component names
   with with computed energy values. Methods which override :oe:meth:`GetFComponents<OEOpt::OEFunc0::GetFComponents>`
   return an iterator over :ref:`OEFComponent <OEOpt_OEFComponent>` instances.
   
   .. oe:method:: Constructors

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

         .. oe:api::

            OEFComponent()
            OEFComponent(const char* n, double v)

      .. oe:language:: python

         .. oe:api:: python

            OEFComponent() -> OEFComponent
            OEFComponent(n: str, v: float) -> OEFComponent

      Default and copy constructors.

      Second constructor makes an instance of :ref:`OEFComponent <OEOpt_OEFComponent>` given a name and value for
      an interaction.

      

