예제 #1
0
 public void EventFollowsEventCountTest()
 {
     Case ca = new Case();
     Event ev1 = new Event {Name = "first"};
     Event ev2 = new Event {Name = "second"};
     ca.EventList.Add(ev1);
     ca.EventList.Add(ev2);
     Assert.IsTrue(ca.EventFollowsEventCount(ev1, ev2)==1,"Count: " + ca.EventFollowsEventCount(ev1,ev2));
 }
예제 #2
0
 /// <summary>
 /// Count how often e2 follows e1.
 /// </summary>
 /// <param name="event1"></param>
 /// <param name="event2"></param>
 /// <returns></returns>
 /// <author>Jannik Arndt</author>
 public int EventFollowsEvent(Event event1, Event event2)
 {
     return(Cases.Sum(Case => Case.EventFollowsEventCount(event1, event2)));
 }