React to ICompileModule change
This commit is contained in:
parent
53f3a91f01
commit
bca294e6e8
|
|
@ -20,7 +20,7 @@ namespace Microsoft.AspNet.Mvc.Razor.Precompilation
|
|||
public class PrecompilationTagHelperTypeResolver : TagHelperTypeResolver
|
||||
{
|
||||
private static readonly string TagHelperTypeName = typeof(ITagHelper).FullName;
|
||||
private readonly IBeforeCompileContext _compileContext;
|
||||
private readonly BeforeCompileContext _compileContext;
|
||||
private readonly IAssemblyLoadContext _loadContext;
|
||||
private object _compilationLock = new object();
|
||||
private bool _assemblyEmited;
|
||||
|
|
@ -29,9 +29,9 @@ namespace Microsoft.AspNet.Mvc.Razor.Precompilation
|
|||
/// <summary>
|
||||
/// Initializes a new instance of <see cref="PrecompilationTagHelperTypeResolver"/>.
|
||||
/// </summary>
|
||||
/// <param name="compileContext">The <see cref="IBeforeCompileContext"/>.</param>
|
||||
/// <param name="compileContext">The <see cref="BeforeCompileContext"/>.</param>
|
||||
/// <param name="loadContext">The <see cref="IAssemblyLoadContext"/>.</param>
|
||||
public PrecompilationTagHelperTypeResolver([NotNull] IBeforeCompileContext compileContext,
|
||||
public PrecompilationTagHelperTypeResolver([NotNull] BeforeCompileContext compileContext,
|
||||
[NotNull] IAssemblyLoadContext loadContext)
|
||||
{
|
||||
_compileContext = compileContext;
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ namespace Microsoft.AspNet.Mvc.Razor.Precompilation
|
|||
public class RazorPreCompiler
|
||||
{
|
||||
public RazorPreCompiler(
|
||||
[NotNull] IBeforeCompileContext compileContext,
|
||||
[NotNull] BeforeCompileContext compileContext,
|
||||
[NotNull] IAssemblyLoadContextAccessor loadContextAccessor,
|
||||
[NotNull] IFileProvider fileProvider,
|
||||
[NotNull] IMemoryCache precompilationCache,
|
||||
|
|
@ -45,7 +45,7 @@ namespace Microsoft.AspNet.Mvc.Razor.Precompilation
|
|||
|
||||
protected IFileProvider FileProvider { get; }
|
||||
|
||||
protected IBeforeCompileContext CompileContext { get; }
|
||||
protected BeforeCompileContext CompileContext { get; }
|
||||
|
||||
protected IAssemblyLoadContext LoadContext { get; }
|
||||
|
||||
|
|
@ -62,7 +62,6 @@ namespace Microsoft.AspNet.Mvc.Razor.Precompilation
|
|||
public virtual void CompileViews()
|
||||
{
|
||||
var result = CreateFileInfoCollection();
|
||||
|
||||
if (result != null)
|
||||
{
|
||||
var collectionGenerator = new RazorFileInfoCollectionGenerator(
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ namespace Microsoft.AspNet.Mvc
|
|||
|
||||
/// <inheritdoc />
|
||||
/// <remarks>Pre-compiles all Razor views in the application.</remarks>
|
||||
public virtual void BeforeCompile(IBeforeCompileContext context)
|
||||
public virtual void BeforeCompile(BeforeCompileContext context)
|
||||
{
|
||||
var compilerOptionsProvider = _appServices.GetRequiredService<ICompilerOptionsProvider>();
|
||||
var loadContextAccessor = _appServices.GetRequiredService<IAssemblyLoadContextAccessor>();
|
||||
|
|
@ -61,13 +61,13 @@ namespace Microsoft.AspNet.Mvc
|
|||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public void AfterCompile(IAfterCompileContext context)
|
||||
public void AfterCompile(AfterCompileContext context)
|
||||
{
|
||||
}
|
||||
|
||||
private static CompilationSettings GetCompilationSettings(
|
||||
ICompilerOptionsProvider compilerOptionsProvider,
|
||||
IProjectContext projectContext)
|
||||
ProjectContext projectContext)
|
||||
{
|
||||
return compilerOptionsProvider.GetCompilerOptions(projectContext.Name,
|
||||
projectContext.TargetFramework,
|
||||
|
|
|
|||
Loading…
Reference in New Issue