Class ErrorSectionPanelViewModel
java.lang.Object
com.inductiveautomation.eventstream.designer.ui.viewmodel.SectionPanelViewModel
com.inductiveautomation.eventstream.designer.ui.viewmodel.error.ErrorSectionPanelViewModel
- All Implemented Interfaces:
ConfigViewModel<OnErrorConfig>, EnabledBindable, Disposable, ViewModel
public class ErrorSectionPanelViewModel
extends SectionPanelViewModel
implements ConfigViewModel<OnErrorConfig>, EnabledBindable
-
Constructor Summary
ConstructorsConstructorDescriptionErrorSectionPanelViewModel(@Nullable EventStreamContext eventStreamContext, ScriptManager scriptManager) Lightweight constructor for demos and tests with no AI grounding.ErrorSectionPanelViewModel(@Nullable EventStreamContext eventStreamContext, ScriptManager scriptManager, Supplier<String> callerContext, ToolBundle sampleTool) -
Method Summary
Modifier and TypeMethodDescription@Nullable DesignerContextThe Designer context backing this section, ornullwhen constructed without an Event Stream context (demos/tests).enabled()voidinitialize(EventStreamConfig config) voidinitialize(OnErrorConfig onError) voidsetEnabled(Boolean enabled) voidsetUserCode(String code) userCode()Methods inherited from class SectionPanelViewModel
clearDiagnostics, createFlowCell, dispose, flowCellData, getName, initialize, lastFlowCellData, onActivate, onDeactivate, onDiagnosticsData, sectionLabel, setFlowCellData, setSectionLabel, setSectionLabelDistinct, setStatus
-
Constructor Details
-
ErrorSectionPanelViewModel
public ErrorSectionPanelViewModel(@Nullable EventStreamContext eventStreamContext, ScriptManager scriptManager) Lightweight constructor for demos and tests with no AI grounding. -
ErrorSectionPanelViewModel
public ErrorSectionPanelViewModel(@Nullable EventStreamContext eventStreamContext, ScriptManager scriptManager, Supplier<String> callerContext, ToolBundle sampleTool) - Parameters:
callerContext- supplies the AI assist's framing for this surface, grounded in the late-stage shape the handlers also see (transform-encoded when a transform is enabled, else source-encoded) and resolved live (built byEventStreamConfigManagerfrom the grounding). Invoked on the EDT at prompt-submit time.sampleTool- the on-demand late-stage sample tool the view installs on this section's AI assist.
-
-
Method Details
-
designerContext
The Designer context backing this section, ornullwhen constructed without an Event Stream context (demos/tests). The view uses it to mount the AI assist button. -
initialize
- Specified by:
initializein classSectionPanelViewModel
-
initialize
- Specified by:
initializein interfaceConfigViewModel<OnErrorConfig>
-
getConfig
- Specified by:
getConfigin interfaceConfigViewModel<OnErrorConfig>
-
setUserCode
-
setEnabled
-
callerContext
-
sampleTool
-
enabled
- Specified by:
enabledin interfaceEnabledBindable
-
userCode
-
compilationResultMessage
-
compilationState
-