Table of Contents

Class JsonLocalizationManager

Namespace
Discord.Interactions
Assembly
Discord.Net.Interactions.dll

The default localization provider for Json resource files.

public sealed class JsonLocalizationManager : ILocalizationManager
Inheritance
JsonLocalizationManager
Implements
Inherited Members

Constructors

JsonLocalizationManager(string, string)

Initializes a new instance of the JsonLocalizationManager class.

public JsonLocalizationManager(string basePath, string fileName)

Parameters

basePath string

Base path of the Json file.

fileName string

Name of the Json file.

Methods

GetAllDescriptions(IList<string>, LocalizationTarget)

Get every the resource description for every available locale.

public IDictionary<string, string> GetAllDescriptions(IList<string> key, LocalizationTarget destinationType)

Parameters

key IList<string>

Location of the resource.

destinationType LocalizationTarget

Type of the resource.

Returns

IDictionary<string, string>

A dictionary containing every available locale and the resource name.

GetAllNames(IList<string>, LocalizationTarget)

Get every the resource name for every available locale.

public IDictionary<string, string> GetAllNames(IList<string> key, LocalizationTarget destinationType)

Parameters

key IList<string>

Location of the resource.

destinationType LocalizationTarget

Type of the resource.

Returns

IDictionary<string, string>

A dictionary containing every available locale and the resource name.