diff --git a/modules/conop/doc/connectivity.rst b/modules/conop/doc/connectivity.rst index 9b56d65662df21b3350d7ce7cdb080bb984263a8..98270b1aff31b7fa6d0f15f526e4dde56e8ef735 100644 --- a/modules/conop/doc/connectivity.rst +++ b/modules/conop/doc/connectivity.rst @@ -258,3 +258,15 @@ The RuleBasedBuilder class :rtype: list of :class:`~ost.mol.AtomHandle` instances +Changing the default builder +--------------------------------------------------------------------------------- + +The default builder can be specified with :func:`SetDefaultBuilder`. Before being +able to set a builder, it needs to be registered with :func:`RegisterBuilder`. +By default, there is always a builder called "HEURISTIC" registered. If, for some +reason your are currently using the :class:`RuleBasedBuilder` and you would like +to switch to that builder, call + +.. code-block:: python + + conop.SetDefaultBuilder("HEURISTIC") diff --git a/modules/conop/pymod/__init__.py b/modules/conop/pymod/__init__.py index a534ea808bf883c616c7eb7165af5b71155fdc5b..a24f5d2ec21b9333c7548cce372739a3c1753e6d 100644 --- a/modules/conop/pymod/__init__.py +++ b/modules/conop/pymod/__init__.py @@ -64,7 +64,12 @@ def RegisterBuilder(builder, name): def SetDefaultBuilder(builder_name): ''' - Set the builder with the given name as the default. + Set the builder with the given name as the default. You will have to register + a builder with :func:`RegisterBuilder` before you will be able to set it as + the default. + + :raises: :exc:`RuntimeError` when trying to set a builder as the default that + has not been registered yet. ''' conop_inst=Conopology.Instance() conop_inst.SetDefaultBuilder(builder_name)