SyntaxGenerator.ConstructorDeclaration 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
ConstructorDeclaration(IMethodSymbol, IEnumerable<SyntaxNode>, IEnumerable<SyntaxNode>)
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
Create a constructor declaration using
public Microsoft.CodeAnalysis.SyntaxNode ConstructorDeclaration (Microsoft.CodeAnalysis.IMethodSymbol constructorMethod, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode> baseConstructorArguments = default, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode> statements = default);
public Microsoft.CodeAnalysis.SyntaxNode ConstructorDeclaration (Microsoft.CodeAnalysis.IMethodSymbol constructorMethod, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode>? baseConstructorArguments = default, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode>? statements = default);
member this.ConstructorDeclaration : Microsoft.CodeAnalysis.IMethodSymbol * seq<Microsoft.CodeAnalysis.SyntaxNode> * seq<Microsoft.CodeAnalysis.SyntaxNode> -> Microsoft.CodeAnalysis.SyntaxNode
Public Function ConstructorDeclaration (constructorMethod As IMethodSymbol, Optional baseConstructorArguments As IEnumerable(Of SyntaxNode) = Nothing, Optional statements As IEnumerable(Of SyntaxNode) = Nothing) As SyntaxNode
参数
- constructorMethod
- IMethodSymbol
- baseConstructorArguments
- IEnumerable<SyntaxNode>
- statements
- IEnumerable<SyntaxNode>
返回
适用于
ConstructorDeclaration(String, IEnumerable<SyntaxNode>, Accessibility, DeclarationModifiers, IEnumerable<SyntaxNode>, IEnumerable<SyntaxNode>)
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
- Source:
- SyntaxGenerator.cs
创建构造函数声明。
public abstract Microsoft.CodeAnalysis.SyntaxNode ConstructorDeclaration (string containingTypeName = default, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode> parameters = default, Microsoft.CodeAnalysis.Accessibility accessibility = Microsoft.CodeAnalysis.Accessibility.NotApplicable, Microsoft.CodeAnalysis.Editing.DeclarationModifiers modifiers = default, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode> baseConstructorArguments = default, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode> statements = default);
public abstract Microsoft.CodeAnalysis.SyntaxNode ConstructorDeclaration (string? containingTypeName = default, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode>? parameters = default, Microsoft.CodeAnalysis.Accessibility accessibility = Microsoft.CodeAnalysis.Accessibility.NotApplicable, Microsoft.CodeAnalysis.Editing.DeclarationModifiers modifiers = default, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode>? baseConstructorArguments = default, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.SyntaxNode>? statements = default);
abstract member ConstructorDeclaration : string * seq<Microsoft.CodeAnalysis.SyntaxNode> * Microsoft.CodeAnalysis.Accessibility * Microsoft.CodeAnalysis.Editing.DeclarationModifiers * seq<Microsoft.CodeAnalysis.SyntaxNode> * seq<Microsoft.CodeAnalysis.SyntaxNode> -> Microsoft.CodeAnalysis.SyntaxNode
Public MustOverride Function ConstructorDeclaration (Optional containingTypeName As String = Nothing, Optional parameters As IEnumerable(Of SyntaxNode) = Nothing, Optional accessibility As Accessibility = Microsoft.CodeAnalysis.Accessibility.NotApplicable, Optional modifiers As DeclarationModifiers = Nothing, Optional baseConstructorArguments As IEnumerable(Of SyntaxNode) = Nothing, Optional statements As IEnumerable(Of SyntaxNode) = Nothing) As SyntaxNode
参数
- containingTypeName
- String
- parameters
- IEnumerable<SyntaxNode>
- accessibility
- Accessibility
- modifiers
- DeclarationModifiers
- baseConstructorArguments
- IEnumerable<SyntaxNode>
- statements
- IEnumerable<SyntaxNode>