コード例 #1
0
 public void AddView(string viewName, string assemblyName)
 {
     lock (_lock)
     {
         viewCache[viewName] = new EmbeddedView { Name = viewName, AssemblyFullName = assemblyName };
     }
 }
コード例 #2
0
        public AssemblyResourceFile(EmbeddedView view, string virtualPath) :
            base(virtualPath)
        {
            if (view == null) throw new ArgumentNullException("view", "EmbeddedView cannot be null.");

            _EmbeddedView = view;
        }
コード例 #3
0
 public void AddView(string viewName, string assemblyName)
 {
     lock (_lock)
     {
         viewCache[viewName] = new EmbeddedView {
             Name = viewName, AssemblyFullName = assemblyName
         };
     }
 }
コード例 #4
0
        public AssemblyResourceFile(EmbeddedView view, string virtualPath) :
            base(virtualPath)
        {
            if (view == null)
            {
                throw new ArgumentNullException("view", "EmbeddedView cannot be null.");
            }

            _EmbeddedView = view;
        }
コード例 #5
0
        public override VirtualFile GetFile(string virtualPath)
        {
            if (!defaultProvider.FileExists(virtualPath) && IsEmbeddedView(virtualPath))
            {
                EmbeddedView embeddedView = embeddedViews.FindEmbeddedView(virtualPath);
                return(new AssemblyResourceFile(embeddedView, virtualPath));
            }

            return(defaultProvider.GetFile(virtualPath));
        }