public NFAGraphNode(DFAGraphNode <T> node) { Name = node.Name; ItIsInitialState = node.ItIsInitialState; ItIsAdmissibleState = node.ItIsAdmissibleState; ConversionTable = node.ConversionTable; }
public string FindTransition(DFAGraphNode <string> q, string delta) { string rtrn = ""; for (int i = 0; i < q.ConversionTable.Count; i++) { if (q.ConversionTable[i].InputCharacter == delta) { rtrn += q.ConversionTable[i].StateSet.Name + " "; } } rtrn = rtrn.Trim(); rtrn = rtrn.Replace(" ", ","); if (rtrn == "") { return(null); } else { return(rtrn); } }
/// <summary> /// Добавить состояние /// </summary> /// <param name="state"></param> public void addState(DFAGraphNode <string> state) { Q.Add(state); }
public void SateStateTransitionTable(DFAGraphNode <string> stateSet, string inputCharacter) { StateSet = stateSet; InputCharacter = inputCharacter; }
public DFAGraphNode <T> GetDFANode() { DFAGraphNode <T> node = new DFAGraphNode <T>(Name, ItIsInitialState, ItIsAdmissibleState); return(node); }
public StateTransitionTable(DFAGraphNode <string> stateSet, string inputCharacter, bool availability) { StateSet = stateSet; InputCharacter = inputCharacter; }
public void AddEntering(DFAGraphNode <T> node) { Entering.Add(node); }