IOC: scoped/on-demand services (#1120)

This commit is contained in:
goat 2023-05-21 22:43:28 +02:00 committed by GitHub
parent ca8a05b672
commit daa9f72218
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 309 additions and 62 deletions

View file

@ -54,7 +54,7 @@ namespace Dalamud.CorePlugin
/// Initializes a new instance of the <see cref="PluginImpl"/> class.
/// </summary>
/// <param name="pluginInterface">Dalamud plugin interface.</param>
public PluginImpl(DalamudPluginInterface pluginInterface)
public PluginImpl(DalamudPluginInterface pluginInterface, PluginLog log)
{
try
{
@ -68,7 +68,7 @@ namespace Dalamud.CorePlugin
Service<CommandManager>.Get().AddHandler("/coreplug", new(this.OnCommand) { HelpMessage = $"Access the {this.Name} plugin." });
PluginLog.Information("CorePlugin ctor!");
log.Information("CorePlugin ctor!");
}
catch (Exception ex)
{