public VoidMethodObjectSourceProxy(object source, MethodInfo methodInfo) : base(source) { if (!methodInfo.ReturnType.Equals(typeof(void))) { throw new ArgumentException("methodInfo"); } this.invoker = methodInfo.AsProxy(source); }
public VoidMethodTargetProxy(object target, MethodInfo methodInfo) { if (!methodInfo.ReturnType.Equals(typeof(void))) { throw new ArgumentException("methodInfo"); } if (target != null) { this.target = new WeakReference(target, true); } this.invoker = methodInfo.AsProxy(target); }