コード例 #1
0
        private List <QueryableObject> QueryEventDispatcher(object[] parameters, QueryFilter filter)
        {
            List <QueryableObject> list            = new List <QueryableObject>(50);
            IList <OnlineDatabase> onlineDatabases = OnlineDiagnostics.Instance.databaseManager.GetOnlineDatabases((Guid?)parameters[0]);

            if (onlineDatabases == null || onlineDatabases.Count != 1)
            {
                throw new ArgumentException("Could not find the database specified by DatabaseGuid", "DatabaseGuid");
            }
            EventControllerPrivate    eventControllerPrivate = (EventControllerPrivate)onlineDatabases[0].EventController;
            IList <MailboxDispatcher> mailboxDispatcher      = eventControllerPrivate.GetMailboxDispatcher((Guid?)parameters[1]);

            if (mailboxDispatcher == null)
            {
                return(list);
            }
            MailboxDispatcher mailboxDispatcher2 = mailboxDispatcher[0];

            foreach (EventDispatcherPrivate eventDispatcherPrivate in mailboxDispatcher2.GetEventDispatcher((Guid?)parameters[2]))
            {
                QueryableEventDispatcher queryableEventDispatcher = new QueryableEventDispatcher();
                eventDispatcherPrivate.ExportToQueryableObject(queryableEventDispatcher);
                if (filter == null || OpathFilterEvaluator.FilterMatches(filter, queryableEventDispatcher))
                {
                    list.Add(queryableEventDispatcher);
                }
            }
            return(list);
        }
コード例 #2
0
        // Token: 0x0600026A RID: 618 RVA: 0x0000D728 File Offset: 0x0000B928
        public override void ExportToQueryableObject(QueryableObject queryableObject)
        {
            base.ExportToQueryableObject(queryableObject);
            QueryableEventDispatcher queryableEventDispatcher = queryableObject as QueryableEventDispatcher;

            if (queryableEventDispatcher != null)
            {
                queryableEventDispatcher.AssistantName        = base.Assistant.Name;
                queryableEventDispatcher.AssistantGuid        = base.Assistant.Identity;
                queryableEventDispatcher.CommittedWatermark   = this.committedWatermark;
                queryableEventDispatcher.HighestEventQueued   = this.highestEventQueued;
                queryableEventDispatcher.RecoveryEventCounter = this.recoveryEventCounter;
                queryableEventDispatcher.IsInRetry            = this.isInRetry;
                queryableEventDispatcher.ActiveQueueLength    = base.ActiveQueue.Count;
                queryableEventDispatcher.PendingQueueLength   = base.PendingQueue.Count;
                queryableEventDispatcher.PendingWorkers       = base.PendingWorkers;
                queryableEventDispatcher.ActiveWorkers        = base.ActiveWorkers;
            }
        }