Class MarkupParameterRenderer
java.lang.Object
uno.anahata.asi.swing.agi.message.part.tool.param.MarkupParameterRenderer
- All Implemented Interfaces:
ParameterRenderer<Object>
A parameter renderer that falls back to standard markdown/HTML rendering.
- Author:
- anahata
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate MarkupTextSegmentRendererThe underlying segment renderer used for the actual markup transformation. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the Swing component that performs the rendering.voidinit(AgiPanel agiPanel, AbstractToolCall<?, ?> call, String paramName, Object value) Initializes the renderer with its context.booleanrender()Triggers the rendering logic.voidupdateContent(Object value) Updates the renderer with a new value.
-
Field Details
-
renderer
The underlying segment renderer used for the actual markup transformation.
-
-
Constructor Details
-
MarkupParameterRenderer
public MarkupParameterRenderer()No-arg constructor for factory instantiation.
-
-
Method Details
-
init
Initializes the renderer with its context.Implementation details: Wraps the value in a
MarkupTextSegmentRendererto support standard Markdown/HTML formatting within the tool call.- Specified by:
initin interfaceParameterRenderer<Object>- Parameters:
agiPanel- The parent agi panel.call- The tool call being rendered.paramName- The name of the parameter.value- The initial value.
-
getComponent
Returns the Swing component that performs the rendering.Implementation details: Delegates to the underlying markup renderer's component.
- Specified by:
getComponentin interfaceParameterRenderer<Object>- Returns:
- The rendering component.
-
updateContent
Updates the renderer with a new value.Implementation details: Resolves the object to a string and pushes it into the markup pipeline.
- Specified by:
updateContentin interfaceParameterRenderer<Object>- Parameters:
value- The new value to render.
-
render
public boolean render()Triggers the rendering logic.Implementation details: Triggers the visual refresh of the markup component.
- Specified by:
renderin interfaceParameterRenderer<Object>- Returns:
- True if a visual update occurred.
-

