protected virtual IMonoRailContainerEx CreateDefaultMonoRailContainer(IServiceProviderEx userServiceProvider, HttpApplication appInstance) { DefaultMonoRailContainerEx container = new DefaultMonoRailContainerEx(userServiceProvider); container.UseServicesFromParent(); container.InstallPrimordialServices(); container.Configure(Configuration); FireContainerCreated(appInstance, container); if (!container.HasService <IServerUtility>()) { container.AddService <IServerUtility>(new ServerUtilityAdapter(appInstance.Context.Server)); } if (!container.HasService <IRoutingEngine>()) { container.AddService <IRoutingEngine>(RoutingModuleEx.Engine); } container.InstallMissingServices(); container.StartExtensionManager(); FireContainerInitialized(appInstance, container); return(container); }
protected virtual IMonoRailContainerEx CreateDefaultMonoRailContainer( IServiceProviderEx userServiceProvider, HttpApplication appInstance ) { DefaultMonoRailContainerEx container = new DefaultMonoRailContainerEx( userServiceProvider ); container.UseServicesFromParent(); container.InstallPrimordialServices(); container.Configure( Configuration ); FireContainerCreated( appInstance, container ); if ( !container.HasService<IServerUtility>() ) { container.AddService<IServerUtility>( new ServerUtilityAdapter( appInstance.Context.Server ) ); } if ( !container.HasService<IRoutingEngine>() ) { container.AddService<IRoutingEngine>( RoutingModuleEx.Engine ); } container.InstallMissingServices(); container.StartExtensionManager(); FireContainerInitialized( appInstance, container ); return container; }