public void Build_Basic_Graph( ) { FlowDiagramControl flowDiagram = new FlowDiagramControl( ); var initialState = new InitialState( ); var dp = new DecisionPoint( ); var finalState = new FinalState( ); flowDiagram.AddShape(initialState); flowDiagram.AddShape(dp); flowDiagram.AddShape(finalState); initialState.Connection.To = dp; dp.True.To = finalState; dp.False.To = finalState; }
// [Test] public void Convert_From_Graph_To_StateMap( ) { FlowDiagramControl flowDiagram = new FlowDiagramControl(); var initialState = new InitialState(); var dp = new DecisionPoint(); var finalState = new FinalState(); flowDiagram.AddShape(initialState); flowDiagram.AddShape(dp); flowDiagram.AddShape(finalState); initialState.Connection.To = dp; dp.True.To = finalState; dp.False.To = finalState; flowDiagram.Convert(false); }