More nzbdrone.exe refactoring.

This commit is contained in:
kay.one
2011-10-06 23:36:04 -07:00
parent 69ba365cd3
commit 8bf4f81a04
30 changed files with 1092 additions and 234 deletions

View File

@@ -1,10 +1,11 @@
using System;
using NLog;
using Ninject;
using NzbDrone.Providers;
namespace NzbDrone
{
internal static class Program
public static class Program
{
public static readonly StandardKernel Kernel = new StandardKernel();
@@ -14,8 +15,20 @@ namespace NzbDrone
{
try
{
Kernel.Bind<ConfigProvider>().ToSelf().InSingletonScope();
Kernel.Bind<ConsoleProvider>().ToSelf().InSingletonScope();
Kernel.Bind<DebuggerProvider>().ToSelf().InSingletonScope();
Kernel.Bind<EnviromentProvider>().ToSelf().InSingletonScope();
Kernel.Bind<IISProvider>().ToSelf().InSingletonScope();
Kernel.Bind<MonitoringProvider>().ToSelf().InSingletonScope();
Kernel.Bind<ProcessProvider>().ToSelf().InSingletonScope();
Kernel.Bind<ServiceProvider>().ToSelf().InSingletonScope();
Kernel.Bind<WebClientProvider>().ToSelf().InSingletonScope();
Console.WriteLine("Starting Console.");
Kernel.Get<MonitoringProvider>().Start();
Kernel.Get<Application>().Start();
}
catch (Exception e)
{