共用方式為


SyntaxFactory.NamedFieldInitializer 方法

定義

多載

NamedFieldInitializer(SyntaxToken, SyntaxToken, IdentifierNameSyntax, SyntaxToken, ExpressionSyntax)

代表 With {...} 初始化運算式中的具名欄位初始化運算式,例如 「.x = expr」。

NamedFieldInitializer(IdentifierNameSyntax, ExpressionSyntax)

代表 With {...} 初始化運算式中的具名欄位初始化運算式,例如 「.x = expr」。

NamedFieldInitializer(SyntaxToken, SyntaxToken, IdentifierNameSyntax, SyntaxToken, ExpressionSyntax)

Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb

代表 With {...} 初始化運算式中的具名欄位初始化運算式,例如 「.x = expr」。

public:
 static Microsoft::CodeAnalysis::VisualBasic::Syntax::NamedFieldInitializerSyntax ^ NamedFieldInitializer(Microsoft::CodeAnalysis::SyntaxToken keyKeyword, Microsoft::CodeAnalysis::SyntaxToken dotToken, Microsoft::CodeAnalysis::VisualBasic::Syntax::IdentifierNameSyntax ^ name, Microsoft::CodeAnalysis::SyntaxToken equalsToken, Microsoft::CodeAnalysis::VisualBasic::Syntax::ExpressionSyntax ^ expression);
public static Microsoft.CodeAnalysis.VisualBasic.Syntax.NamedFieldInitializerSyntax NamedFieldInitializer (Microsoft.CodeAnalysis.SyntaxToken keyKeyword, Microsoft.CodeAnalysis.SyntaxToken dotToken, Microsoft.CodeAnalysis.VisualBasic.Syntax.IdentifierNameSyntax name, Microsoft.CodeAnalysis.SyntaxToken equalsToken, Microsoft.CodeAnalysis.VisualBasic.Syntax.ExpressionSyntax expression);
static member NamedFieldInitializer : Microsoft.CodeAnalysis.SyntaxToken * Microsoft.CodeAnalysis.SyntaxToken * Microsoft.CodeAnalysis.VisualBasic.Syntax.IdentifierNameSyntax * Microsoft.CodeAnalysis.SyntaxToken * Microsoft.CodeAnalysis.VisualBasic.Syntax.ExpressionSyntax -> Microsoft.CodeAnalysis.VisualBasic.Syntax.NamedFieldInitializerSyntax
Public Shared Function NamedFieldInitializer (keyKeyword As SyntaxToken, dotToken As SyntaxToken, name As IdentifierNameSyntax, equalsToken As SyntaxToken, expression As ExpressionSyntax) As NamedFieldInitializerSyntax

參數

keyKeyword
SyntaxToken

選擇性的 「Key」 關鍵字。

dotToken
SyntaxToken

「.」 權杖。

name
IdentifierNameSyntax

要初始化的功能變數名稱。

equalsToken
SyntaxToken

「=」 權杖。

expression
ExpressionSyntax

指派給欄位的值。

傳回

適用於

NamedFieldInitializer(IdentifierNameSyntax, ExpressionSyntax)

Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb
Source:
Syntax.xml.Main.Generated.vb

代表 With {...} 初始化運算式中的具名欄位初始化運算式,例如 「.x = expr」。

public:
 static Microsoft::CodeAnalysis::VisualBasic::Syntax::NamedFieldInitializerSyntax ^ NamedFieldInitializer(Microsoft::CodeAnalysis::VisualBasic::Syntax::IdentifierNameSyntax ^ name, Microsoft::CodeAnalysis::VisualBasic::Syntax::ExpressionSyntax ^ expression);
public static Microsoft.CodeAnalysis.VisualBasic.Syntax.NamedFieldInitializerSyntax NamedFieldInitializer (Microsoft.CodeAnalysis.VisualBasic.Syntax.IdentifierNameSyntax name, Microsoft.CodeAnalysis.VisualBasic.Syntax.ExpressionSyntax expression);
static member NamedFieldInitializer : Microsoft.CodeAnalysis.VisualBasic.Syntax.IdentifierNameSyntax * Microsoft.CodeAnalysis.VisualBasic.Syntax.ExpressionSyntax -> Microsoft.CodeAnalysis.VisualBasic.Syntax.NamedFieldInitializerSyntax
Public Shared Function NamedFieldInitializer (name As IdentifierNameSyntax, expression As ExpressionSyntax) As NamedFieldInitializerSyntax

參數

name
IdentifierNameSyntax

要初始化的功能變數名稱。

expression
ExpressionSyntax

指派給欄位的值。

傳回

適用於