Table of Contents

Method ToStringFast

Namespace
DSharpPlus.Entities
Assembly
DSharpPlus.dll

ToStringFast(DiscordPermission, bool)

Returns the string representation of the DiscordPermission value. If the attribute is decorated with a [Display] or [Description]attribute, then uses the provided value. Otherwise uses the name of the member, equivalent to calling ToString() on value.

public static string ToStringFast(this DiscordPermission value, bool useMetadataAttributes)

Parameters

value DiscordPermission

The value to retrieve the string value for

useMetadataAttributes bool

If true uses the value provided in the [Display] or [Description]attribute as the string representation of the member. If false, always uses the name of the member, the same as if ToString() was called.

Returns

string

The string representation of the value

ToStringFast(DiscordPermission)

Returns the string representation of the DiscordPermission value. Directly equivalent to calling ToString() on value.

public static string ToStringFast(this DiscordPermission value)

Parameters

value DiscordPermission

The value to retrieve the string value for

Returns

string

The string representation of the value, the same as that returned by ToString()