THE ORIONIS API
Build with clarity.
Explore the building blocks of an async-first Python framework. Every module, class, and method — connected, searchable, and ready to build with.
class documentation
class LocalizationManager(ILocalizationManager): (source)
Constructor: LocalizationManager(app)
Wire the localization component from the application configuration.
The manager reads the app.locale, app.fallback_locale, and app.language_path settings, builds the loader, the repository, and the translator, and caches the resulting translator so a single shared instance serves the whole application.
| Method | __build |
Build the translator from the application configuration. |
| Method | __init__ |
Initialize the manager with the application container. |
| Method | translator |
Return the shared translator instance, building it on demand. |
| Class Variable | __slots__ |
Undocumented |
| Instance Variable | _app |
Undocumented |
| Instance Variable | _translator |
Undocumented |
Build the translator from the application configuration.
| Returns | |
ITranslator | Translator bound to a fresh loader and repository. |
| Raises | |
InvalidLocaleException | If the configured locale or fallback locale is malformed. |
Initialize the manager with the application container.
| Parameters | |
app:IApplication | Application container providing configuration and paths. |
| Returns | |
None | Undocumented |
Return the shared translator instance, building it on demand.
| Returns | |
ITranslator | Translator configured from the application settings. |
| Raises | |
InvalidLocaleException | If the configured locale or fallback locale is malformed. |