• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# IResourceHandler类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中IResourceHandler的典型用法代码示例。如果您正苦于以下问题:C# IResourceHandler类的具体用法?C# IResourceHandler怎么用?C# IResourceHandler使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



IResourceHandler类属于命名空间,在下文中一共展示了IResourceHandler类的17个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: OnInit

        protected override void OnInit(EventArgs e)
        {
            base.OnInit(e);
            _resourceHandler = IoC.Get<IResourceHandler>();
            //_resourceHandler.AddjQuery(Page);
            _resourceHandler.AddjQueryNivoSlider(Page);
            _resourceHandler.AddNivoSliderStyleSheet(Page);

            AddThemeStylesheet();
        }
开发者ID:kirolosgerges,项目名称:Blog,代码行数:10,代码来源:PropertyImageSlideShowViewModeControl.ascx.cs


示例2: RegisterHandler

 public virtual bool RegisterHandler(string url, IResourceHandler handler)
 {
     Uri uri;
     if (Uri.TryCreate(url, UriKind.Absolute, out uri))
     {
         Handlers.AddOrUpdate(uri.ToString(), handler, (k, v) => handler);
         return true;
     }
     return false;
 }
开发者ID:kirkita,项目名称:CefSharp,代码行数:10,代码来源:DefaultResourceHandlerFactory.cs


示例3: RegisterHandler

 public virtual bool RegisterHandler(string url, IResourceHandler handler)
 {
     Uri uri;
     if (Uri.TryCreate(url, UriKind.Absolute, out uri)) {
         lock (Handlers) {
             Handlers[uri.ToString()] = handler;
         }
         return true;
     }
     return false;
 }
开发者ID:bartwe,项目名称:CefSharp,代码行数:11,代码来源:DefaultResourceHandlerFactory.cs


示例4: GlobalSettingsPresenter

        public GlobalSettingsPresenter(
            IGlobalSettingsView view,
            ITranslator translator,
            IGlobalSettingsRepository globalSettingsRepository,
            IResourceHandler resourceHandler)
        {
            if (view == null) throw new ArgumentNullException("view");
            if (translator == null) throw new ArgumentNullException("translator");
            if (globalSettingsRepository == null) throw new ArgumentNullException("globalSettingsRepository");
            if (resourceHandler == null) throw new ArgumentNullException("resourceHandler");
            _view = view;
            _translator = translator;
            _globalSettingsRepository = globalSettingsRepository;
            _resourceHandler = resourceHandler;

            _view.SaveGlobalSettings += SaveGlobalSettings;
            _view.ResetGlobalSettings += ResetGlobalSettings;
        }
开发者ID:kirolosgerges,项目名称:Blog,代码行数:18,代码来源:GlobalSettingsPresenter.cs


示例5: PageTypePickerPresenter

 public PageTypePickerPresenter(
     IPageTypePickerView view,
     ITranslator translator,
     IResourceHandler resourceHandler,
     IPageTypeWrapper pageType,
     HttpContextBase context)
 {
     if (view == null) throw new ArgumentNullException("view");
     if (translator == null) throw new ArgumentNullException("translator");
     if (resourceHandler == null) throw new ArgumentNullException("resourceHandler");
     if (pageType == null) throw new ArgumentNullException("pageType");
     if (context == null) throw new ArgumentNullException("context");
     _view = view;
     _translator = translator;
     _resourceHandler = resourceHandler;
     _pageType = pageType;
     _context = context;
     _log = Log.For(this);
 }
开发者ID:kirolosgerges,项目名称:Blog,代码行数:19,代码来源:PageTypePickerPresenter.cs


示例6: UserSettingsPresenter

        public UserSettingsPresenter(
            IUserSettingsView view,
            ITranslator translator,
            IGlobalSettingsRepository globalSettingsRepository,
            IResourceHandler resourceHandler,
            HttpContextBase context)
        {
            if (view == null) throw new ArgumentNullException("view");
            if (translator == null) throw new ArgumentNullException("translator");
            if (globalSettingsRepository == null) throw new ArgumentNullException("globalSettingsRepository");
            if (resourceHandler == null) throw new ArgumentNullException("resourceHandler");
            if (context == null) throw new ArgumentNullException("context");
            _view = view;
            _translator = translator;
            _globalSettingsRepository = globalSettingsRepository;
            _resourceHandler = resourceHandler;
            _context = context;
            _log = Log.For(this);

            _view.LoadUserSettings += HandleLoadSettings;
            _view.SaveUserSettings += HandleSaveSettings;
        }
开发者ID:kirolosgerges,项目名称:Blog,代码行数:22,代码来源:UserSettingsPresenter.cs


示例7: OnEndLoad

		protected override void OnEndLoad ()
		{
			// The resource handler policy may have changed after loading, so reset any
			// previously allocated resource handler
			resourceHandler = null;

			// Just after loading, the resource Ids are using the file format's policy.
			// They have to be converted to the new policy
			IResourceHandler handler = ItemHandler as IResourceHandler;
			if (handler != null)
				MigrateResourceIds (handler, ResourceHandler);

			base.OnEndLoad ();
		}
开发者ID:John-Colvin,项目名称:monodevelop,代码行数:14,代码来源:DotNetProject.cs


示例8: SetItemHandler

		internal override void SetItemHandler (ISolutionItemHandler handler)
		{
			if (ProjectExtensionUtil.GetItemHandler (this) == null) {
				// Initial assignment of the item handler
				base.SetItemHandler (handler);
				return;
			}
			IResourceHandler rh = ResourceHandler;

			base.SetItemHandler (handler);
			resourceHandler = null;
			// A change in the file format may imply a change in the resource naming policy.
			// Make sure that the resource Id don't change.
			MigrateResourceIds (rh, ResourceHandler);
		}
开发者ID:John-Colvin,项目名称:monodevelop,代码行数:15,代码来源:DotNetProject.cs


示例9: OnEndLoad

		protected override void OnEndLoad ()
		{
			// The resource handler policy may have changed after loading, so reset any
			// previously allocated resource handler
			resourceHandler = null;

			// Just after loading, the resource Ids are using the file format's policy.
			// They have to be converted to the new policy
			IResourceHandler handler = ItemHandler as IResourceHandler;
			if (handler != null)
				MigrateResourceIds (handler, ResourceHandler);
			
			if (String.IsNullOrEmpty (defaultNamespace))
				defaultNamespace = SanitisePotentialNamespace (Name);

			base.OnEndLoad ();
		}
开发者ID:raufbutt,项目名称:monodevelop-old,代码行数:17,代码来源:DotNetProject.cs


示例10: GetResourceId

		internal string GetResourceId (IResourceHandler resourceHandler)
		{
			if (string.IsNullOrEmpty (resourceId))
				return resourceHandler.GetDefaultResourceId (this);
			return resourceId;
		}
开发者ID:nerzhulart,项目名称:monodevelop,代码行数:6,代码来源:ProjectFile.cs


示例11: PageExplorerAdapter

 public PageExplorerAdapter()
 {
     _translator = IoC.Get<ITranslator>();
     _resourceHandler = IoC.Get<IResourceHandler>();
     _roleStrategy = IoC.Get<IRoleStrategy>();
 }
开发者ID:kirolosgerges,项目名称:Blog,代码行数:6,代码来源:PageExplorerAdapter.cs


示例12: ConversionManager

 public ConversionManager(IResourceHandler fileHandler, IResourceHandler registryHandler, IEncoder encoder)
 {
     _fileHandler = fileHandler;
     _registryHandler = registryHandler;
     _encoder = encoder;
 }
开发者ID:binglot,项目名称:Bin2Reg,代码行数:6,代码来源:ConversionManager.cs


示例13: UpdateResourceHandler

		public void UpdateResourceHandler (bool keepOldIds)
		{
			IResourceHandler oldHandler = resourceHandler;
			resourceHandler = null;
			if (keepOldIds && oldHandler != null)
				MigrateResourceIds (oldHandler, ResourceHandler);
		}
开发者ID:John-Colvin,项目名称:monodevelop,代码行数:7,代码来源:DotNetProject.cs


示例14: MigrateResourceIds

		void MigrateResourceIds (IResourceHandler oldHandler, IResourceHandler newHandler)
		{
			if (oldHandler.GetType () != newHandler.GetType ()) {
				// If the file format has a default resource handler different from the one
				// choosen for this project, then all resource ids must be converted
				foreach (ProjectFile file in Files.Where (f => f.BuildAction == BuildAction.EmbeddedResource)) {
					if (file.Subtype == Subtype.Directory)
						continue;
					string oldId = file.GetResourceId (oldHandler);
					string newId = file.GetResourceId (newHandler);
					string newDefault = newHandler.GetDefaultResourceId (file);
					if (oldId != newId) {
						if (newDefault == oldId)
							file.ResourceId = null;
						else
							file.ResourceId = oldId;
					} else {
						if (newDefault == oldId)
							file.ResourceId = null;
					}
				}
			}
		}
开发者ID:John-Colvin,项目名称:monodevelop,代码行数:23,代码来源:DotNetProject.cs


示例15: RegisterHandler

 public virtual void RegisterHandler(string url, IResourceHandler handler)
 {
     Handlers[url] = handler;
 }
开发者ID:klkn,项目名称:CefSharp,代码行数:4,代码来源:DefaultResourceHandlerFactory.cs


示例16: HttpDiagnosticsService

 public HttpDiagnosticsService(IServiceConfiguration configuration)
 {
     this.configuration = configuration;
     collector = new TimeSeriesCollector();
     carbonWriter = CarbonWriterFactory.Instance();
     graphDataHandler = new GraphDataHandler(collector);
 }
开发者ID:lovewitty,项目名称:OstrichNet,代码行数:7,代码来源:HttpDiagnosticsService.cs


示例17: UpdateDependentObjects

 private static void UpdateDependentObjects()
 {
     s_HtmlPageMinifier = new DefaultHtmlPageMinifier(s_HtmlMinifier, new DefaultInlineJavascriptMinifier(s_JsMinifier), new DefaultInlineCssMinifier(s_CssMinifier));
     s_ResourceCacher = new DefaultResourceCacher(s_CacheProvider);
     s_ResourceReader = new ResourceReaderManager(() => new EmbeddedResourceResolver(), () => new FileSystemResourceReader(s_VirtualPathResolverManager), () => new HttpResourceReader(s_RemoteFileTempFolderProvider, s_VirtualPathProvider));
     s_WebResourceConfiguration = new ResourceXmlConfigurationProvider(s_CacheProvider, s_VirtualPathResolverManager, s_ResourceCacher);
     s_ResourceProcessor = new ResourceProcessor(s_ResourceCacher, s_ResourceReader, s_CompressionFactory, s_ResourceHasher, s_JsMinifier, s_CssMinifier, s_VirtualPathProvider);
     s_ResourceHandler = new ResourceHandler(s_ResourceProcessor, s_WebResourceConfiguration, s_HttpResponseCacher, s_HttpResponseCompressor);
     s_ResourceManager = new ResourceManager(s_ResourceProcessor, s_WebResourceConfiguration, s_HttpResponseCompressor);
 }
开发者ID:LaboFoundation,项目名称:Labo.WebSiteOptimizer,代码行数:10,代码来源:ResourceManagerRuntime.cs



注:本文中的IResourceHandler类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# IResourceLoader类代码示例发布时间:2022-05-24
下一篇:
C# IResourceAccessor类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap