Пример #1
0
        public void TestClassDiagram1()
        {
            var document = TestHelper.SetupDocument(@"C:\temp\commontext.cs", Host);

            var w       = new Window();
            var diagram = new ClassDiagram {
                Document = document
            };
            var grid = new Grid();

            grid.Children.Add(diagram);
            w.Content = grid;
            w.ShowDialog();
        }
Пример #2
0
        public void TestWalkerr1()
        {
            var        document = TestHelper.SetupDocument(@"C:\Users\mccor.LAPTOP-T6T0BN1K\source\repos\KayMcCormick.Dev\src\RoslynCodeControls\src\RoslynCodeControls\LineInfo2.cs", Host);
            SyntaxTree tree     = null;

            JoinableTaskFactory.Run(async() =>
            {
                tree = await GetDocumentSyntaxTreeAsync(document);
            });
            var walker = new Walker();

            walker.Visit(tree.GetRoot());
            DumpNodes(walker.CompilationUnitNode);
        }