public static bool TryCalculateConversationCreatorSidOnDeliveryProcessing(MailboxSession mailboxSession, ICorePropertyBag itemPropertyBag, ConversationIndex.FixupStage fixupStage, ConversationIndex conversationIndex, out byte[] conversationCreatorSid, out bool updateAllConversationMessages)
 {
     conversationCreatorSid        = null;
     updateAllConversationMessages = false;
     if (!ConversationCreatorHelper.SupportsConversationCreator(mailboxSession))
     {
         return(false);
     }
     byte[] valueOrDefault = itemPropertyBag.GetValueOrDefault <byte[]>(InternalSchema.SenderSID, null);
     return(ConversationCreatorHelper.TryCalculateConversationCreatorSid(mailboxSession, itemPropertyBag, fixupStage, conversationIndex, valueOrDefault, out conversationCreatorSid, out updateAllConversationMessages));
 }
 private static bool TryCalculateConversationCreatorSid(MailboxSession mailboxSession, ICorePropertyBag itemPropertyBag, ConversationIndex.FixupStage fixupStage, ConversationIndex conversationIndex, byte[] itemOwnerSID, out byte[] conversationCreatorSid, out bool updateAllConversationMessages)
 {
     ConversationCreatorHelper.ConversationCreatorDefinitionData definitionData          = new ConversationCreatorHelper.ConversationCreatorDefinitionData(mailboxSession, conversationIndex);
     ConversationCreatorHelper.MessageDeliveryScenario           messageDeliveryScenario = ConversationCreatorHelper.CalculateConversationDeliveryScenario(definitionData, itemPropertyBag, fixupStage);
     return(ConversationCreatorHelper.TryCalculateConversationCreatorSid(definitionData, messageDeliveryScenario, itemOwnerSID, out conversationCreatorSid, out updateAllConversationMessages));
 }