WindsorStaticCommandServiceLoader.cs
Home
/
src /
Web /
Infrastructure /
WindsorStaticCommandServiceLoader.cs
namespace Web.Infrastructure
{
using Castle.Windsor;
using DotVVM.Framework.Hosting;
using DotVVM.Framework.Runtime;
using System;
public class WindsorStaticCommandServiceLoader : DefaultStaticCommandServiceLoader
{
private readonly WindsorContainer _container;
public WindsorStaticCommandServiceLoader(WindsorContainer container)
{
_container = container;
}
public override object GetStaticCommandService(Type serviceType, IDotvvmRequestContext context)
{
return _container.Resolve(serviceType);
}
}
}