Exemplo n.º 1
0
        protected virtual void RaiseComplete(TaskCompleteEventArgs e)
        {
            EventHandler <TaskCompleteEventArgs> h = Completed;

            if (h != null)
            {
                h(this, e);
            }
        }
Exemplo n.º 2
0
        private void TaskComplete(object o, TaskCompleteEventArgs e)
        {
            task.Completed -= TaskComplete;

            SendQueryEventArgs args = (SendQueryEventArgs)e;
            if (args.TimedOut)
            {
                bucket.SortBySeen();
                int index = bucket.Nodes.IndexOf(node);
                if (index == -1 || (++index < bucket.Nodes.Count))
                {
                    QueryNode(bucket.Nodes[0]);
                }
                else
                {
                    RaiseComplete(new TaskCompleteEventArgs(this));
                }
            }
            else
            {
                RaiseComplete(new TaskCompleteEventArgs(this));
            }
        }
Exemplo n.º 3
0
        private void TaskComplete(object o, TaskCompleteEventArgs e)
        {
            task.Completed -= TaskComplete;

            SendQueryEventArgs args = (SendQueryEventArgs)e;

            if (args.TimedOut)
            {
                bucket.SortBySeen();
                int index = bucket.Nodes.IndexOf(node);
                if (index == -1 || (++index < bucket.Nodes.Count))
                {
                    QueryNode(bucket.Nodes[0]);
                }
                else
                {
                    RaiseComplete(new TaskCompleteEventArgs(this));
                }
            }
            else
            {
                RaiseComplete(new TaskCompleteEventArgs(this));
            }
        }
Exemplo n.º 4
0
 protected virtual void RaiseComplete(TaskCompleteEventArgs e)
 {
     EventHandler<TaskCompleteEventArgs> h = Completed;
     if (h != null)
         h(this, e);
 }
Exemplo n.º 5
0
 protected virtual void RaiseComplete(TaskCompleteEventArgs e)
 {
     var h = Completed;
     if (h != null)
         h(this, e);
 }