bool SentByThis(ExportsChangeEventArgs e) { return(e is TaggedExportsChangedEventArgs && ((TaggedExportsChangedEventArgs)e).Sender == this); }
private void ExportProvider_ExportsChanged([CanBeNull] object sender, [CanBeNull] ExportsChangeEventArgs e) { UpdateTarget(); }
/// <summary> /// Determines if the specified event arguments were sent by this instance. /// </summary> /// <param name="e">The event arguments.</param> /// <returns>True if the specified event arguments were sent by this instance, otherwise false.</returns> private bool SelfSent(ExportsChangeEventArgs e) { return(e is TaggedExportsChangeEventArgs && ((TaggedExportsChangeEventArgs)e).Sender == this); }
private static void Container_ExportsChanged(object sender, ExportsChangeEventArgs e) { Console.Write("Added Exports: "); Console.WriteLine(string.Join(", ", e.AddedExports)); }
private void ExportProvider_ExportsChanged(object?sender, ExportsChangeEventArgs e) { ExportsChanged?.Invoke(sender, e); }
private void OnContainerExportsChanged(object sender, ExportsChangeEventArgs e) { ExportsChanged?.Invoke(this, e); }
void provider_ExportsChanged(object sender, ExportsChangeEventArgs args) { Contract.Requires <ArgumentNullException>(sender != null); Contract.Requires <ArgumentNullException>(args != null); OnExportsChanged(args); }