コード例 #1
0
        // Token: 0x06000FC8 RID: 4040 RVA: 0x00040810 File Offset: 0x0003EA10
        public List <RecipientInfoCacheEntry> Load(string parentXmlNodeName)
        {
            this.CheckDisposed("Load");
            if (string.IsNullOrEmpty(parentXmlNodeName))
            {
                throw new ArgumentException("parentXmlNodeName is null or Empty");
            }
            List <RecipientInfoCacheEntry> result;

            using (Stream xmlStream = this.backendUserConfiguration.GetXmlStream())
            {
                this.lastModifiedTime = this.backendUserConfiguration.LastModifiedTime;
                result = RecipientInfoCache.Deserialize(xmlStream, parentXmlNodeName, out this.backendCacheVersion);
            }
            return(result);
        }
コード例 #2
0
 // Token: 0x06001098 RID: 4248 RVA: 0x00043E78 File Offset: 0x00042078
 public SmsRecipientInfoCache(MailboxSession mailboxSession, Trace tracer)
 {
     if (mailboxSession == null)
     {
         throw new ArgumentNullException("mailboxSession");
     }
     if (tracer == null)
     {
         throw new ArgumentNullException("tracer");
     }
     this.MailboxSession     = mailboxSession;
     this.Tracer             = tracer;
     this.RecipientInfoCache = RecipientInfoCache.Create(this.MailboxSession, "SMS.RecipientInfoCache");
     try
     {
         this.CacheEntries = this.RecipientInfoCache.Load("AutoCompleteCache");
     }
     catch (CorruptDataException)
     {
         this.Tracer.TraceDebug <string>((long)this.GetHashCode(), "The SMS recipient cache is corrupt in {0}'s mailbox", mailboxSession.MailboxOwner.MailboxInfo.DisplayName);
     }
 }
コード例 #3
0
 // Token: 0x06000FC9 RID: 4041 RVA: 0x00040884 File Offset: 0x0003EA84
 public void Save(List <RecipientInfoCacheEntry> entries, string parentNodeName, int cacheSize)
 {
     this.CheckDisposed("Save");
     if (entries == null)
     {
         throw new ArgumentNullException("entries");
     }
     if (string.IsNullOrEmpty(parentNodeName))
     {
         throw new ArgumentException("parentNodeName is null or Empty");
     }
     if (cacheSize <= 0)
     {
         throw new ArgumentException("cacheSize must be greater than zero");
     }
     using (Stream xmlStream = this.backendUserConfiguration.GetXmlStream())
     {
         RecipientInfoCache.Serialize(xmlStream, entries, parentNodeName, cacheSize);
     }
     try
     {
         this.backendUserConfiguration.Save();
     }
     catch (ObjectNotFoundException ex)
     {
         ExTraceGlobals.StorageTracer.TraceDebug <string>(0L, "RecipientInfoCache.Commit: Failed. Exception: {0}", ex.Message);
     }
     catch (QuotaExceededException ex2)
     {
         ExTraceGlobals.StorageTracer.TraceDebug <string>(0L, "RecipientInfoCache.Commit: Failed. Exception: {0}", ex2.Message);
     }
     catch (SaveConflictException ex3)
     {
         ExTraceGlobals.StorageTracer.TraceDebug <string>(0L, "RecipientInfoCache.Commit: Failed. Exception: {0}", ex3.Message);
     }
 }