protected internal override void Define() { On((Attach x) => observer = x.Observer); On((Publish x) => observer.Notify(new Notification { Text = x.Text })); }
void On(Publish x) => observer.Notify(new Notification { Text = x.Text });
public static void Notify <TEvent>(this ObserverRef @ref, TEvent @event) where TEvent : Event { @ref.Notify(@event); }