Beispiel #1
0
 public override void Invoke(object[] args)
 {
     if (args.Length != 1)
     {
         throw new ArgumentException("Passed argument 'args' is invalid size. Expected size is 1");
     }
     BaseInvokableCall.ThrowOnInvalidArg <T1>(args[0]);
     if (BaseInvokableCall.AllowInvoke(this.Delegate))
     {
         this.Delegate((T1)((object)args[0]));
     }
 }
 public override void Invoke(object[] args)
 {
     if (args.Length != 2)
     {
         throw new ArgumentException("Passed argument 'args' is invalid size. Expected size is 1");
     }
     BaseInvokableCall.ThrowOnInvalidArg <T1>(args[0]);
     BaseInvokableCall.ThrowOnInvalidArg <T2>(args[1]);
     if (!BaseInvokableCall.AllowInvoke((System.Delegate) this.Delegate))
     {
         return;
     }
     this.Delegate((T1)args[0], (T2)args[1]);
 }
Beispiel #3
0
 public override void Invoke(object[] args)
 {
     if (args.Length != 4)
     {
         throw new ArgumentException("Passed argument 'args' is invalid size. Expected size is 1");
     }
     BaseInvokableCall.ThrowOnInvalidArg <T1>(args[0]);
     BaseInvokableCall.ThrowOnInvalidArg <T2>(args[1]);
     BaseInvokableCall.ThrowOnInvalidArg <T3>(args[2]);
     BaseInvokableCall.ThrowOnInvalidArg <T4>(args[3]);
     if (BaseInvokableCall.AllowInvoke(this.Delegate))
     {
         this.Delegate((T1)args[0], (T2)args[1], (T3)args[2], (T4)args[3]);
     }
 }