public void AddTransition(Transition tran) { if (OutgoingTransitions == null) { OutgoingTransitions = new List<Transition>(); } OutgoingTransitions.Add(tran); }
/// <summary> /// Remove transition for list and its source state's outgoing list /// </summary> /// <param name="toRemove"></param> public void RemoveTransition(Transition toRemove) { Transitions.Remove(toRemove); toRemove.FromState.OutgoingTransitions.Remove(toRemove); toRemove.ToState.IncomingTransition.Remove(toRemove); }
public void AddTransition(Transition toAdd) { Transitions.Add(toAdd); toAdd.FromState.OutgoingTransitions.Add(toAdd); toAdd.ToState.IncomingTransition.Add(toAdd); }