Skip to content

Allow generic parameter in renderer setter method #36

@federicoisaia

Description

@federicoisaia

Feature proposal

It would be nice to add support for using a generic parameter in the renderer setter method. The method signature should be updated to setRenderer(Renderer), allowing the renderer to operate on any type that extends Message. This will increase flexibility and type safety when working with different message types in the Chat Assistant add-on.

Describe solution expectations

The setRenderer method should be refactored to accept a generic type parameter T that must extend Message. For example:

public void setRenderer(Renderer renderer)

This change will enable developers to provide custom renderers for specific subclasses of Message, without losing type information.

Additional information

No response

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requestjavaPull requests that update java code

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions