public void UpdateRecipientSyncStateValue(RecipientSyncOperation operation)
        {
            Dictionary <string, HashSet <string> > dictionary = new Dictionary <string, HashSet <string> >(MserveTargetConnection.ReplicationAddressAttributes.Length, StringComparer.OrdinalIgnoreCase);

            foreach (string text in MserveTargetConnection.ReplicationAddressAttributes)
            {
                string recipientSyncStateAttribute = MserveTargetConnection.GetRecipientSyncStateAttribute(operation.RecipientSyncState, text);
                dictionary[text] = RecipientSyncState.AddressHashSetFromConcatStringValue(recipientSyncStateAttribute);
            }
            foreach (OperationType key in operation.PendingSyncStateCommitEntries.Keys)
            {
                foreach (string text2 in operation.PendingSyncStateCommitEntries[key])
                {
                    string key2 = null;
                    if (!operation.AddressTypeTable.TryGetValue(text2, out key2))
                    {
                        throw new InvalidOperationException(text2 + " is not in AddressTypeTable");
                    }
                    switch (key)
                    {
                    case OperationType.Add:
                        if (!dictionary[key2].Contains(text2))
                        {
                            dictionary[key2].Add(text2);
                        }
                        break;

                    case OperationType.Delete:
                        if (dictionary[key2].Contains(text2))
                        {
                            dictionary[key2].Remove(text2);
                        }
                        break;
                    }
                }
            }
            foreach (string text3 in MserveTargetConnection.ReplicationAddressAttributes)
            {
                MserveTargetConnection.SetRecipientSyncStateAttribute(operation.RecipientSyncState, text3, RecipientSyncState.AddressHashSetToConcatStringValue(dictionary[text3]));
            }
        }
        private static void OnAddressChange(DirectoryAttribute attribute, RecipientSyncOperation operation)
        {
            HashSet <string> hashSet = RecipientSyncState.AddressHashSetFromConcatStringValue(MserveTargetConnection.GetRecipientSyncStateAttribute(operation.RecipientSyncState, attribute.Name));

            foreach (object obj in attribute)
            {
                string text = (string)obj;
                string text2;
                if (text.StartsWith("smtp:", StringComparison.OrdinalIgnoreCase))
                {
                    text2 = text.Substring(5);
                }
                else if (text.StartsWith("meum:", StringComparison.OrdinalIgnoreCase))
                {
                    text2 = text.Substring(5);
                }
                else
                {
                    text2 = text;
                }
                if (!hashSet.Contains(text2))
                {
                    operation.AddedEntries.Add(text2);
                    operation.AddressTypeTable[text2] = attribute.Name;
                    ExTraceGlobals.TargetConnectionTracer.TraceDebug <string>(0L, "Add {0} to AddedEntries", text2);
                }
                else
                {
                    hashSet.Remove(text2);
                }
            }
            foreach (string text3 in hashSet)
            {
                operation.RemovedEntries.Add(text3);
                operation.AddressTypeTable[text3] = attribute.Name;
                ExTraceGlobals.TargetConnectionTracer.TraceDebug <string>(0L, "Add {0} to RemovedEntries", text3);
            }
        }