New to Telerik UI for WPFStart a free 30-day trial

Converts between MessageModel and MessageBase types for use in the spreadsheet AI chat UI.

Definition

Namespace:Telerik.Windows.Controls.Spreadsheet.AI

Assembly:Telerik.Windows.Controls.Spreadsheet.dll

Syntax:

C#
public class SpreadsheetMessageConverter : IMessageConverter

Inheritance: objectSpreadsheetMessageConverter

Implements: IMessageConverter

Constructors

Initializes a new instance of the SpreadsheetMessageConverter class.

C#
public SpreadsheetMessageConverter(string aiAuthorName)
Parameters:aiAuthorNamestring

The display name of the AI author.

Methods

Converts a MessageModel to a MessageBase instance.

C#
public MessageBase ConvertItem(object item)
Parameters:itemobject

The item to convert, expected to be of type MessageModel.

Returns:

MessageBase

A TextMessage representing the message.

Implements: IMessageConverter.ConvertItem(object)

Converts a MessageBase instance to a MessageModel.

C#
public object ConvertMessage(MessageBase message)
Parameters:messageMessageBase

The message to convert, expected to be of type TextMessage.

Returns:

object

A MessageModel representing the message.

Implements: IMessageConverter.ConvertMessage(MessageBase)