Method TrySetTitleAsync
- Namespace
- MailFathom.Application.Agent.Conversations
- Assembly
- MailFathom.Application.dll
TrySetTitleAsync(AgentConversationId, UserId, PresentationText, CancellationToken)
Names a conversation, which the agent does once it has read the first question.
Task<bool> TrySetTitleAsync(AgentConversationId id, UserId user, PresentationText title, CancellationToken cancellationToken)
Parameters
idAgentConversationIdThe conversation to name.
userUserIdThe person whose conversation it has to be.
titlePresentationTextWhat to call it, at most MaximumTitleLength characters.
cancellationTokenCancellationTokenCancels the write.
Returns
Remarks
It leaves the instant the history is ordered by alone, a name being a fact about the conversation rather than a turn of it, and it writes over whatever name the conversation held, so a later naming is the one that stands. The person is checked as in every other method here: the agent naming a conversation always knows whose it is answering in, so nothing is bought by making this the one write a caller could point anywhere.
Exceptions
- ArgumentException
Thrown when
titleis the unspecified default or is longer than the bound.