예제 #1
0
        public AssmanContext BuildContext(ResourceMode resourceMode, bool usePreCompilationReportIfPresent = true)
        {
            IResourceFinder             fileFinder           = ResourceFinderFactory.Null;
            IPreCompiledReportPersister preCompiledPersister = NullPreCompiledPersister.Instance;

            if (!String.IsNullOrEmpty(RootFilePath))
            {
                fileFinder = ResourceFinderFactory.GetInstance(RootFilePath);
                if (usePreCompilationReportIfPresent)
                {
                    preCompiledPersister = CompiledFilePersister.ForWebDirectory(RootFilePath);
                }
            }

            return(BuildContext(resourceMode, fileFinder, preCompiledPersister));
        }
예제 #2
0
 public void AddAssembly(Assembly assembly)
 {
     _assemblies.Add(assembly);
     _compositeFinder.AddFinder(ResourceFinderFactory.GetInstance(assembly));
 }