search and ai stabilization work, localization stablized.
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
namespace StellaOps.Localization;
|
||||
|
||||
/// <summary>
|
||||
/// Provides translation bundles from a specific source (embedded JSON, remote API, etc.).
|
||||
/// Providers are loaded in priority order: lower priority values are loaded first and
|
||||
/// overwritten by higher-priority providers.
|
||||
/// </summary>
|
||||
public interface ITranslationBundleProvider
|
||||
{
|
||||
/// <summary>
|
||||
/// Priority: lower = loaded first (overwritten by higher).
|
||||
/// Common embedded = 0, service embedded = 10, remote/DB = 100.
|
||||
/// </summary>
|
||||
int Priority { get; }
|
||||
|
||||
/// <summary>Load all translation key-value pairs for a locale.</summary>
|
||||
Task<IReadOnlyDictionary<string, string>> LoadAsync(string locale, CancellationToken ct);
|
||||
|
||||
/// <summary>Which locales this provider can serve.</summary>
|
||||
Task<IReadOnlyList<string>> GetAvailableLocalesAsync(CancellationToken ct);
|
||||
}
|
||||
Reference in New Issue
Block a user