TomlInlineTableSyntax Class

An inline table: braces around a comma-separated list of key/value pairs, such as { x = 1, y = 2 }.

public sealed class TomlInlineTableSyntax : TomlValueSyntax
Inheritance
TomlValueSyntax TomlInlineTableSyntax

Properties

NameDescription
CloseBraceToken
OpenBraceToken
PropertiesGets the key/value pairs of the table. The commas between them are the separators of the list.
public SyntaxToken CloseBraceToken { get; }

Property value

SyntaxToken

No documentation is available.

public SyntaxToken OpenBraceToken { get; }

Property value

SyntaxToken

No documentation is available.

Gets the key/value pairs of the table. The commas between them are the separators of the list.

public SeparatedSyntaxList<TomlPropertySyntax> Properties { get; }

Methods

NameDescription
Accept(TomlSyntaxVisitor)
Accept<TResult>(TomlSyntaxVisitor<TResult>)
AddProperties(TomlPropertySyntax[])Returns this inline table with items added at the end, laid out the way the table already is.
Update(SyntaxToken, SeparatedSyntaxList<TomlPropertySyntax>, SyntaxToken)Returns this inline table with the given parts, or itself when nothing changed.
WithCloseBraceToken(SyntaxToken)
WithOpenBraceToken(SyntaxToken)
WithProperties(SeparatedSyntaxList<TomlPropertySyntax>)

Accept overloads

Accept(TomlSyntaxVisitor)

TomlInlineTableSyntax.cs
public override void Accept(TomlSyntaxVisitor visitor)
Parameters
visitor TomlSyntaxVisitor

No documentation is available.

Accept<TResult>(TomlSyntaxVisitor<TResult>)

TomlInlineTableSyntax.cs
public override TResult? Accept<TResult>(TomlSyntaxVisitor<TResult> visitor)
Type parameters
TResult
Parameters
visitor TomlSyntaxVisitor<TResult>
Returns

TResult?

No documentation is available.

AddProperties(TomlPropertySyntax[])

TomlInlineTableSyntax.cs

Returns this inline table with items added at the end, laid out the way the table already is.

public TomlInlineTableSyntax AddProperties(params TomlPropertySyntax[] items)

Parameters

items TomlPropertySyntax[]

Returns

TomlInlineTableSyntax

Exceptions

ArgumentNullException
items or one of its items is null.

Remarks

In a table written on one line, each new key/value pair follows a comma and a space, and an empty table gets a space inside each brace. In one written a pair per line, each goes on a line of its own, indented as the last one is. A pair that ends with a comment gets a line break after it, or the comment would hide what follows it.

Update(SyntaxToken, SeparatedSyntaxList<TomlPropertySyntax>, SyntaxToken)

TomlInlineTableSyntax.cs

Returns this inline table with the given parts, or itself when nothing changed.

public TomlInlineTableSyntax Update(SyntaxToken openBraceToken, SeparatedSyntaxList<TomlPropertySyntax> properties, SyntaxToken closeBraceToken)

Parameters

openBraceToken SyntaxToken
properties SeparatedSyntaxList<TomlPropertySyntax>
closeBraceToken SyntaxToken

Returns

TomlInlineTableSyntax

WithCloseBraceToken(SyntaxToken)

TomlInlineTableSyntax.cs
public TomlInlineTableSyntax WithCloseBraceToken(SyntaxToken closeBraceToken)

Parameters

closeBraceToken SyntaxToken

Returns

TomlInlineTableSyntax

No documentation is available.

WithOpenBraceToken(SyntaxToken)

TomlInlineTableSyntax.cs
public TomlInlineTableSyntax WithOpenBraceToken(SyntaxToken openBraceToken)

Parameters

openBraceToken SyntaxToken

Returns

TomlInlineTableSyntax

No documentation is available.

WithProperties(SeparatedSyntaxList<TomlPropertySyntax>)

TomlInlineTableSyntax.cs

No documentation is available.