WidgetFunction¶
-
class
orion_notebook.widgets.widget_function.
FunctionWidget
(**kwargs)¶ Bases:
orion_notebook.widgets.widget_base.RuntimeWidget
Class for building a Function Widget.
Input(s):
Operation:
Outputs(s):
-
add_dynamic_input
(traitlet: object, visible: bool = False) → None¶ Adds a dynamic traitlet to the widget
- Parameters
traitlet (object) – The traitlet to be added
visible (bool) – Whether the traitlet is to be rendered in the notebook (default False)
-
add_sources
(widgets: List[orion_notebook.widgets.widget_base.BaseWidget])¶ Adds several widgets to the list of widgets the current widget is linked to
- Parameters
widgets (List[BaseWidget]) – List of widgets that feed data to the current widget
-
configure_outputs
()¶ Configures the outputs of the widget
-
execute
(**kwargs)¶ Configures the widget’s functionality and generates the function widget
-
manage_dynamic_inputs
(widgets: List[orion_notebook.widgets.widget_base.BaseWidget])¶ Creates a dynamic input for each of the outputs of the given widget
- Parameters
widgets (List[BaseWidget]) – List of widgets that feed data to the current widget
-
pin_dynamic_input
(name: str, attr: str = 'value') → Tuple[Any, str]¶ Builds a linkable pin on an attribute of a specific dynamic input entity. By default, the attribute is set to ‘value’
- Parameters
name (str) – Name of the dynamic input
attr (str) – Name of the attribute of the dynamic input entity (default ‘value’)
- Returns
The linkable pin on a dynamic input
- Raises
OrionNotebookException – Output or attribute does not exist for that dynamic input entity