コード例 #1
0
        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;
        }
コード例 #2
0
        //    [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);
        }