From c08fd0aefeea1628fe93c818ca4dde63fd6ac2e1 Mon Sep 17 00:00:00 2001 From: Rob Mensching Date: Tue, 17 Oct 2017 02:47:44 -0700 Subject: Introduce WixToolsetServiceProvider Using a service provider allows all of WixToolset.Core's internal functionality to be abstracted behind interfaces in WixToolset.Extensibility. The service provide can also control what interfaces are singletons. --- src/WixToolset.Core/BindContext.cs | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/WixToolset.Core/BindContext.cs') diff --git a/src/WixToolset.Core/BindContext.cs b/src/WixToolset.Core/BindContext.cs index 499f3245..7b1a1877 100644 --- a/src/WixToolset.Core/BindContext.cs +++ b/src/WixToolset.Core/BindContext.cs @@ -2,12 +2,21 @@ namespace WixToolset.Core { + using System; using System.Collections.Generic; using WixToolset.Data; using WixToolset.Extensibility; + using WixToolset.Extensibility.Services; public class BindContext : IBindContext { + internal BindContext(IServiceProvider serviceProvider) + { + this.ServiceProvider = serviceProvider; + } + + public IServiceProvider ServiceProvider { get; } + public Messaging Messaging { get; set; } public IEnumerable BindPaths { get; set; } -- cgit v1.2.3-55-g6feb