public WeakActionSubscriber(object target, MethodInfo method) { Should.NotBeNull(target, nameof(target)); Should.NotBeNull(method, nameof(method)); _reference = ToolkitExtensions.GetWeakReference(target); _method = method; _delegate = (Action <object, object, T>)ToolkitServiceProvider .ReflectionManager .GetMethodDelegate(typeof(Action <object, object, T>), method); _hash = ActionSubscriber <object> .ActionSubscriberGetHashCode(target, method); }
public override bool Equals(object obj) { return(ActionSubscriber <object> .ActionSubscriberEquals(this, obj as IActionSubscriber)); }
public bool Equals(ISubscriber other) { return(ActionSubscriber <object> .ActionSubscriberEquals(this, other as IActionSubscriber)); }