private void ExecuteTransition(StateVertex targetStateVertex) { currentStateVertex?.OnExit(); currentStateVertex = targetStateVertex; currentStateVertex?.OnEnter(); }
public StateTransition Target(StateVertex target) { if (TargetStateVertex != null) { throw new Exception("Duplicated transition target"); } TargetStateVertex = target; TargetStateVertex.AddIncomingTransition(this); return(this); }
public void AddVertex(StateVertex vertex) { Vertices.Add(vertex); }
public void PrepareTransition(StateVertex targetStateVertex) { ExecuteTransition(targetStateVertex); }
public StateTransition(StateVertex source) { SourceStateVertex = source; }
private void AddVertex(StateVertex vertex) { stateChart.AddVertex(vertex); }