ChatHistory.IndexOf(ChatMessageContent) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Searches for the specified message and returns the index of the first occurrence.
public int IndexOf (Microsoft.SemanticKernel.ChatMessageContent item);
abstract member IndexOf : Microsoft.SemanticKernel.ChatMessageContent -> int
override this.IndexOf : Microsoft.SemanticKernel.ChatMessageContent -> int
Public Function IndexOf (item As ChatMessageContent) As Integer
Parameters
- item
- ChatMessageContent
The message to locate.
Returns
The index of the first found occurrence of the specified message; -1 if the message could not be found.
Implements
Exceptions
item
is null.