示例#1
0
            private static void ProcessNodeMembers(TreeTextSpan.Builder builder, SyntaxList <MemberDeclarationSyntax> members)
            {
                foreach (var namespaceDeclaration in members.OfType <NamespaceDeclarationSyntax>())
                {
                    var childBuilder = builder.AddChild(namespaceDeclaration.FullSpan.Start);
                    childBuilder.SetEnd(namespaceDeclaration.FullSpan.End);

                    ProcessNodeMembers(childBuilder, namespaceDeclaration.Members);
                }
            }
示例#2
0
            private static void ProcessNodeMembers(TreeTextSpan.Builder builder, SyntaxList <MemberDeclarationSyntax> members)
            {
                foreach (var namespaceDeclaration in members.Where(member => BaseNamespaceDeclarationSyntaxWrapper.IsInstance(member)))
                {
                    var childBuilder = builder.AddChild(namespaceDeclaration.FullSpan.Start);
                    childBuilder.SetEnd(namespaceDeclaration.FullSpan.End);

                    ProcessNodeMembers(childBuilder, ((BaseNamespaceDeclarationSyntaxWrapper)namespaceDeclaration).Members);
                }
            }