コード例 #1
0
        /// <summary>
        /// Moves node to a new line, indents it and visit it using provided rewriter.
        /// </summary>
        protected SyntaxNode RewriteGenericNode(GenericNameSyntax node, BqlRewriterBase rewriter)
        {
            GenericNameSyntax newNode = OnNewLineAndIndented(node);

            if (newNode?.TypeArgumentList == null)
            {
                return(node);
            }

            TypeArgumentListSyntax newTypeArgsListNode = rewriter.Visit(newNode.TypeArgumentList) as TypeArgumentListSyntax;

            if (newTypeArgsListNode == null)
            {
                return(newNode);
            }

            return(newNode.WithTypeArgumentList(newTypeArgsListNode));
        }
コード例 #2
0
 public BqlConditionRewriter(BqlRewriterBase parent, SyntaxTriviaList defaultLeadingTrivia)
     : base(parent, defaultLeadingTrivia)
 {
     _externalMode = true;
 }
コード例 #3
0
 public BqlStatementRewriter(BqlRewriterBase parent, SyntaxTriviaList defaultLeadingTrivia)
     : base(parent, defaultLeadingTrivia)
 {
 }
コード例 #4
0
 public BqlAggregateRewriter(BqlRewriterBase parent, SyntaxTriviaList defaultLeadingTrivia)
     : base(parent, defaultLeadingTrivia)
 {
 }
コード例 #5
0
 protected BqlRewriterBase(BqlRewriterBase parent, SyntaxTriviaList defaultLeadingTrivia)
     : this(parent.Context, parent._semanticModel,
            parent.EndOfLineTrivia, parent.IndentationTrivia, defaultLeadingTrivia)
 {
 }
コード例 #6
0
 public BqlFirstTableRewriter(BqlRewriterBase parent, SyntaxTriviaList defaultLeadingTrivia)
     : base(parent, defaultLeadingTrivia)
 {
 }
コード例 #7
0
        /// <summary>
        /// Moves node to a new line, indents it and visit it using provided rewriter.
        /// </summary>
        protected SyntaxNode RewriteGenericNode(GenericNameSyntax node, BqlRewriterBase rewriter)
        {
            var newNode = OnNewLineAndIndented(node);

            return(newNode.WithTypeArgumentList((TypeArgumentListSyntax)rewriter.Visit(newNode.TypeArgumentList)));
        }
コード例 #8
0
 public BqlViewDeclarationRewriter(BqlRewriterBase parent, SyntaxTriviaList defaultLeadingTrivia)
     : base(parent, defaultLeadingTrivia)
 {
 }