// Token: 0x06001461 RID: 5217 RVA: 0x0007C5C4 File Offset: 0x0007A7C4
 internal void RemoveSubscription(ConnectionDroppedNotificationHandler connectionDroppedNotificationHandler)
 {
     lock (this.syncRoot)
     {
         if (!this.userContext.LockedByCurrentThread())
         {
             throw new InvalidOperationException("UserContext lock should be acquired before calling this method");
         }
         if (connectionDroppedNotificationHandler != null)
         {
             connectionDroppedNotificationHandler.OnConnectionDropped -= this.HandleConnectionDroppedNotification;
         }
         this.needReinitSubscriptions = true;
         this.payload.DetachFolderContentChangeNotificationHandler(this.contextFolderId);
         ExTraceGlobals.NotificationsCallTracer.TraceDebug <string>((long)this.GetHashCode(), "Removed folder content change notification subscription for user {0}", this.MailboxSessionDisplayName);
     }
 }
        // Token: 0x0600145F RID: 5215 RVA: 0x0007C450 File Offset: 0x0007A650
        internal bool TrySubscribe(ConnectionDroppedNotificationHandler connectionDroppedNotificationHandler)
        {
            bool result;

            lock (this.syncRoot)
            {
                if (this.isDisposed)
                {
                    throw new InvalidOperationException("Cannot call Subscribe on a Disposed object");
                }
                if (!this.userContext.LockedByCurrentThread())
                {
                    throw new InvalidOperationException("UserContext lock should be acquired before calling this method");
                }
                ExTraceGlobals.NotificationsCallTracer.TraceDebug <string>((long)this.GetHashCode(), "Subscribing for folder content change notifications for user {0}", this.MailboxSessionDisplayName);
                try
                {
                    this.InitSubscription();
                }
                catch (MapiExceptionObjectDisposed)
                {
                    OwaMapiNotificationHandler.DisposeXSOObjects(this.result);
                    return(false);
                }
                catch (ObjectDisposedException)
                {
                    return(false);
                }
                catch (StoragePermanentException)
                {
                    return(false);
                }
                catch (StorageTransientException)
                {
                    return(false);
                }
                this.payload.AttachFolderContentChangeNotificationHandler(this.contextFolderId, this);
                connectionDroppedNotificationHandler.OnConnectionDropped += this.HandleConnectionDroppedNotification;
                result = true;
            }
            return(result);
        }
 // Token: 0x06000841 RID: 2113 RVA: 0x0003D014 File Offset: 0x0003B214
 public ConnectionDroppedPayload(UserContext userContext, MailboxSession mailboxSession, ConnectionDroppedNotificationHandler notificationHandler)
 {
     this.userContext = userContext;
     this.mailboxSessionDisplayName = string.Copy(mailboxSession.DisplayName);
     this.notificationHandler       = notificationHandler;
     this.payloadString             = string.Empty;
 }