public RazorPageResolver(IRazorConfig config, RazorViewManager viewManager) { this.RequestName = "Razor_PageResolver"; this.config = config; this.viewManager = viewManager; }
public FileSystemWatcherLiveReload(RazorViewManager views) { this.views = views; }
static ILiveReload CreateLiveReload(RazorViewManager viewManager) { return new FileSystemWatcherLiveReload(viewManager); }
public virtual RazorFormat Init() { if (Instance != null) { Log.Warn("RazorFormat plugin should only be initialized once"); if (ViewManager != null && PageResolver != null) return this; Log.Warn("Incomplete initialization, RazorFormat.Instance set but ViewManager/PageResolver is null"); } Instance = this; this.ViewManager = CreateViewManager(); this.PageResolver = CreatePageResolver(); this.ViewManager.Init(); if (EnableLiveReload.GetValueOrDefault()) { this.LiveReload = LiveReloadFactory(this.ViewManager); this.LiveReload.StartWatching(this.ScanRootPath); } return this; }