Exemple #1
0
 public void Run(Future future)
 {
     CallOnBackground(future);
 }
Exemple #2
0
        object ISynchronizeInvoke.Invoke(Delegate method, object[] args)
        {
            Future <object> f = this.CallOnBackground(() => method.DynamicInvoke(args));

            return(f.Wait());
        }
Exemple #3
0
 internal TypedFutureWatcher(SynchronizationContext context, Future <T> wf, Action <FutureWatcherCompleted <T> > callback)
     : base(context, wf)
 {
     m_wf       = wf;
     m_callback = callback;
 }
Exemple #4
0
 internal EmptyFutureWatcher(SynchronizationContext context, Future future, Action <FutureWatcherCompleted> callback)
     : base(context, future)
 {
     m_wf       = future;
     m_callback = callback;
 }
Exemple #5
0
 public static FutureWatcher Create <T>(SynchronizationContext context, Future <T> future, Action <FutureWatcherCompleted <T> > callback)
 {
     return(new TypedFutureWatcher <T>(context, future, callback));
 }
Exemple #6
0
 public static FutureWatcher Create(SynchronizationContext context, Future future, Action <FutureWatcherCompleted> callback)
 {
     return(new EmptyFutureWatcher(context, future, callback));
 }
Exemple #7
0
 private void OnWatchableFutureCompleted(Future future)
 {
     m_context.Post(() => OnWatchableFutureCompletedCore());
 }