public void TriggerEvent1() { if (Event1 != null) { Event1.Invoke(this, new Event1Args($"Total subscribers: ${Event1.GetInvocationList().Length}")); } }
public void RaiseEvents() { Event1.Invoke(); // have difference of 20 ms between both events Thread.Sleep(20); Event2.Invoke(); }
public bool Equals(Carbrand car) { if (car == null) { return(false); } if (car.LandProducer == "Russia") { Event1?.Invoke(); } else { Event2?.Invoke(); } return(car.LandProducer == "Russia"); }
public void RaiseEvent1() { Event1?.Invoke(this, 777); }
public void RaiseEvent1() { Event1?.Invoke(this, EventArgs.Empty); }
public void RaiseEvent() { Event1?.Invoke(); }
private void Button_Click1(object sender, RoutedEventArgs e) { Event1.Invoke(sender, e); }
public void Trigger() => Event1?.Invoke(1);
public void RaiseEvent1() { //if(Event1 != null) // Event1(this, EventArgs.Empty); Event1?.Invoke(this, EventArgs.Empty); }
public void OnEvent1(int n) { Event1?.Invoke(n); }