public void Register( IAppHost appHost ) { this.AppHost = appHost; this.ViewManager = new ViewManager( appHost, this.ViewConfig ); this.BuildManager = new BuildManager( appHost, this.BuildConfig ); this.PageResolver = new PageResolver( appHost, this.ResolveConfig, this.ViewManager, this.BuildManager ); }
public PageResolver( IAppHost appHost, PageResolverConfig pageResolverConfig, ViewManager viewManager, BuildManager buildManager ) { this.RequestName = "Razor_PageResolver"; this.appHost = appHost; this.pathProvider = appHost.VirtualPathProvider; this.Config = pageResolverConfig; this.viewManager = viewManager; this.buildManager = buildManager; this.appHost.CatchAllHandlers.Add( OnCatchAll ); this.appHost.ViewEngines.Add( this ); }
public void Register(IAppHost appHost) { if (Instance != null) { Log.Warn("RazorFormat plugin should only be registered once"); return; } Instance = this; this.AppHost = appHost; this.ViewManager = new ViewManager(appHost, this.ViewConfig); this.BuildManager = new BuildManager(appHost, this.BuildConfig); this.PageResolver = new PageResolver(appHost, this.ResolveConfig, this.ViewManager, this.BuildManager); }