protected void Init() { m_VATsMaterial = m_meshRenderer.material; m_cachingManager = new CachingManager(); m_cachingManager.Init(typeof(ShaderValues), Shader.PropertyToID); m_VATsMaterial.SetColor(m_cachingManager[ShaderValues._HighlightColor], m_highlightColour); }
/// <summary>查询所有相关记录</summary> /// <returns>返回所有 实例<see cref="RegionInfo"/>的详细信息</returns> public IList <RegionInfo> FindAll() { IList <RegionInfo> data = (IList <RegionInfo>)CachingManager.Get("Location-Regions"); if (data == null) { data = this.provider.FindAll(new DataQuery() { Length = int.MaxValue }); CachingManager.Set("Location-Regions", data); } return(data); }
/// <summary> /// 启动。 /// </summary> public void Startup() => CachingManager.RegisterProvider(new RedisCachingProvider(), Level.Second);
private void LoadData() { CachingManager.PerformXMLDocumentCaching(Application); }
public void TestAdd() { CachingManager.Add("a", 123); CachingManager.Get("a"); }
/// <summary> /// 启动。 /// </summary> public void Startup() => CachingManager.RegisterProvider(new MemoryCachingProvider(), Level.First);