private static void OnEventsOnRuleFiringEvent(object sa, AgendaEventArgs args) { var sb = new StringBuilder(); sb.Append("rule firing:"); sb.Append(args.Rule.Name); sb.Append(args.Rule.Description); sb.AppendFormat("tags: {0}", string.Join(",",args.Rule.Tags)); Debug.WriteLine(sb.ToString()); }
public void RaiseRuleFired(ISession session, Activation activation) { var handler = RuleFiredEvent; if (handler != null) { var @event = new AgendaEventArgs(activation.Rule, activation.Tuple); handler(session, @event); } }
public void RaiseRuleFiring(ISession session, Activation activation) { var handler = RuleFiringEvent; if (handler != null) { var @event = new AgendaEventArgs(activation); handler(session, @event); } _parent?.RaiseRuleFiring(session, activation); }
public void RaiseActivationDeleted(ISession session, Activation activation) { var handler = ActivationDeletedEvent; if (handler != null) { var @event = new AgendaEventArgs(activation); handler(session, @event); } _parent?.RaiseActivationDeleted(session, activation); }
public void RaiseRuleFired(ISession session, IActivation activation) { var handler = RuleFiredEvent; if (handler != null) { var @event = new AgendaEventArgs(activation); handler(session, @event); } if (_parent != null) { _parent.RaiseRuleFired(session, activation); } }
public void RaiseActivationUpdated(ISession session, Activation activation) { var handler = ActivationUpdatedEvent; if (handler != null) { var @event = new AgendaEventArgs(activation.Rule, activation.Tuple); handler(session, @event); } if (_parent != null) { _parent.RaiseActivationUpdated(session, activation); } }
private void OnRuleFired(object sender, AgendaEventArgs args) { Log.InfoFormat("Rule fired. Rule={0}", args.Rule.Name); }
private static void OnEventsOnRuleFiredEvent(object sa, AgendaEventArgs args) { Debug.WriteLine("rule fired:" + args.Rule.Name); }
static void OnActivationDeletedEvent(object sender, AgendaEventArgs args) { Debug.WriteLine("activation deleted"); }
static void OnActivationCreatedEvent(object sender, AgendaEventArgs args) { Debug.WriteLine("activation created:" + args.Rule.Name); }
private static void EventProviderOnActivationCreatedEvent(object sender, AgendaEventArgs e) { Console.WriteLine("+A({0}): {1}", e.Rule.Name, string.Join(",", e.Facts.Select(f => f.Value).ToArray())); }
public void RaiseRuleFired(ISession session, Activation activation) { var handler = RuleFiredEvent; if (handler != null) { var @event = new AgendaEventArgs(activation.Rule, activation.Tuple); handler(session, @event); } if (_parent != null) { _parent.RaiseRuleFired(session, activation); } }