internal ChatMessage(string id, ChatMessageType type, string sequenceId, string version, ChatMessageContent content, string senderDisplayName, DateTimeOffset createdOn, string senderId, DateTimeOffset?deletedOn, DateTimeOffset?editedOn)
 {
     Id                = id;
     Type              = type;
     SequenceId        = sequenceId;
     Version           = version;
     Content           = content;
     SenderDisplayName = senderDisplayName;
     CreatedOn         = createdOn;
     Sender            = new CommunicationUserIdentifier(senderId);
     DeletedOn         = deletedOn;
     EditedOn          = editedOn;
 }
 internal ChatMessage(ChatMessageInternal chatMessageInternal)
 {
     Id                = chatMessageInternal.Id;
     Type              = chatMessageInternal.Type;
     SequenceId        = chatMessageInternal.SequenceId;
     Version           = chatMessageInternal.Version;
     Content           = new ChatMessageContent(chatMessageInternal.Content);
     SenderDisplayName = chatMessageInternal.SenderDisplayName;
     CreatedOn         = chatMessageInternal.CreatedOn;
     if (chatMessageInternal.SenderId != null)
     {
         Sender = new CommunicationUserIdentifier(chatMessageInternal.SenderId);
     }
     DeletedOn = chatMessageInternal.DeletedOn;
     EditedOn  = chatMessageInternal.EditedOn;
 }
Exemplo n.º 3
0
 internal ChatMessage(ChatMessageInternal chatMessageInternal)
 {
     Id                = chatMessageInternal.Id;
     Type              = chatMessageInternal.Type;
     SequenceId        = chatMessageInternal.SequenceId;
     Version           = chatMessageInternal.Version;
     Content           = new ChatMessageContent(chatMessageInternal.Content);
     SenderDisplayName = chatMessageInternal.SenderDisplayName;
     CreatedOn         = chatMessageInternal.CreatedOn;
     if (chatMessageInternal.SenderCommunicationIdentifier != null)
     {
         Sender = CommunicationIdentifierSerializer.Deserialize(chatMessageInternal.SenderCommunicationIdentifier);
     }
     DeletedOn = chatMessageInternal.DeletedOn;
     EditedOn  = chatMessageInternal.EditedOn;
     Metadata  = chatMessageInternal.Metadata;
 }
 public static ChatMessage ChatMessage(string id, ChatMessageType type, string sequenceId, string version, ChatMessageContent content, string senderDisplayName, DateTimeOffset createdOn, string senderId, DateTimeOffset?deletedOn, DateTimeOffset?editedOn)
 => ChatMessage(id, type, sequenceId, version, content, senderDisplayName, createdOn, senderId, deletedOn, editedOn, null);
 public static ChatMessage ChatMessage(string id, ChatMessageType type, string sequenceId, string version, ChatMessageContent content, string senderDisplayName, DateTimeOffset createdOn, string senderId, DateTimeOffset?deletedOn, DateTimeOffset?editedOn, IReadOnlyDictionary <string, string> metadata)
 => new ChatMessage(id, type, sequenceId, version, content, senderDisplayName, createdOn, senderId, deletedOn, editedOn, metadata);