TomlNamingPolicy Class

Determines the naming policy used to convert a CLR member name to a TOML key.

public abstract class TomlNamingPolicy

Constructors

NameDescription
TomlNamingPolicy()Initializes a new instance of the TomlNamingPolicy class.

TomlNamingPolicy()

TomlNamingPolicy.cs

Initializes a new instance of the TomlNamingPolicy class.

protected TomlNamingPolicy()

Properties

NameDescription
CamelCaseGets the naming policy for camelCase.
KebabCaseLowerGets the naming policy for kebab-case (lowercase).
KebabCaseUpperGets the naming policy for KEBAB-CASE (uppercase).
PascalCaseGets the naming policy for PascalCase.
SnakeCaseLowerGets the naming policy for snake_case (lowercase).
SnakeCaseUpperGets the naming policy for SNAKE_CASE (uppercase).

Gets the naming policy for camelCase.

public static TomlNamingPolicy CamelCase { get; }

Property value

TomlNamingPolicy

KebabCaseLower

TomlNamingPolicy.cs

Gets the naming policy for kebab-case (lowercase).

public static TomlNamingPolicy KebabCaseLower { get; }

Property value

TomlNamingPolicy

KebabCaseUpper

TomlNamingPolicy.cs

Gets the naming policy for KEBAB-CASE (uppercase).

public static TomlNamingPolicy KebabCaseUpper { get; }

Property value

TomlNamingPolicy

Gets the naming policy for PascalCase.

public static TomlNamingPolicy PascalCase { get; }

Property value

TomlNamingPolicy

SnakeCaseLower

TomlNamingPolicy.cs

Gets the naming policy for snake_case (lowercase).

public static TomlNamingPolicy SnakeCaseLower { get; }

Property value

TomlNamingPolicy

SnakeCaseUpper

TomlNamingPolicy.cs

Gets the naming policy for SNAKE_CASE (uppercase).

public static TomlNamingPolicy SnakeCaseUpper { get; }

Property value

TomlNamingPolicy

Methods

NameDescription
ConvertName(string)Converts the specified name according to the policy.

ConvertName(string)

Converts the specified name according to the policy.

public abstract string ConvertName(string name)

Parameters

name string
The CLR member name.

Returns

string The converted name.