✅ The verified answer to this question is available below. Our community-reviewed solutions help you understand the material better.
public class DiGuiFactory : IGUIFactory
{
private readonly IServiceProvider _sp;
public DiGuiFactory(IServiceProvider sp) => _sp = sp;
public IButton CreateButton() => _sp.GetRequiredService
();
public ICheckbox CreateCheckbox() => _sp.GetRequiredService
();
}
Що робить цю фабрику потенційно порушенням принципу Abstract Factory?