internal void FireOnUpdateCompleted(TreeUpdateType updateType) {
if (_ownerThread != Thread.CurrentThread.ManagedThreadId) {
Debug.Fail(_threadContextInvalidMessage);
return;
}
try {
UpdateCompleted?.Invoke(this, new TreeUpdatedEventArgs(updateType));
} catch (Exception ex) {
Debug.Assert(false, Invariant($"Exception thrown in a tree.UpdateCompleted event handler: {ex.Message}"));
}
}
}