Class ResxLocalizationManager
The default localization provider for Resx files.
Implements
Namespace: Discord.Interactions
Assembly: Discord.Net.Interactions.dll
Syntax
public sealed class ResxLocalizationManager : object, ILocalizationManager
Constructors
| Improve this Doc View SourceResxLocalizationManager(String, Assembly, CultureInfo[])
Initializes a new instance of the ResxLocalizationManager class.
Declaration
public ResxLocalizationManager(string baseResource, Assembly assembly, params CultureInfo[] supportedLocales)
Parameters
Type | Name | Description |
---|---|---|
String | baseResource | Name of the base resource. |
Assembly | assembly | The main assembly for the resources. |
CultureInfo[] | supportedLocales | Cultures the ResxLocalizationManager should search for. |
Methods
| Improve this Doc View SourceGetAllDescriptions(IList<String>, LocalizationTarget)
Get every the resource description for every available locale.
Declaration
public IDictionary<string, string> GetAllDescriptions(IList<string> key, LocalizationTarget destinationType)
Parameters
Type | Name | Description |
---|---|---|
IList<String> | key | Location of the resource. |
LocalizationTarget | destinationType | Type of the resource. |
Returns
Type | Description |
---|---|
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.
Declaration
public IDictionary<string, string> GetAllNames(IList<string> key, LocalizationTarget destinationType)
Parameters
Type | Name | Description |
---|---|---|
IList<String> | key | Location of the resource. |
LocalizationTarget | destinationType | Type of the resource. |
Returns
Type | Description |
---|---|
IDictionary<String, String> | A dictionary containing every available locale and the resource name. |