Rewrite huge parts of the localization class to support plurals and localized date time formating, also created a TranslationGuildContext class for use in commands

This commit is contained in:
runebaas 2019-05-12 00:17:34 +02:00
parent 4143180b42
commit 8effc42f92
No known key found for this signature in database
GPG key ID: 2677AF508D0300D6
5 changed files with 211 additions and 79 deletions

View file

@ -7,8 +7,10 @@ namespace Geekbot.net.Lib.Localization
public interface ITranslationHandler
{
Task<string> GetString(ulong guildId, string command, string stringName);
List<string> GetStrings(string language, string command, string stringName);
Task<Dictionary<string, string>> GetDict(ICommandContext context);
Task<Dictionary<string, string>> GetDict(ICommandContext context, string command);
Task<TranslationGuildContext> GetGuildContext(ICommandContext context);
Task<bool> SetLanguage(ulong guildId, string language);
List<string> SupportedLanguages { get; }
}