MemoryCacheElement 类
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
定义用于配置基于类的缓存的 MemoryCache 元素。 此类不能被继承。
public ref class MemoryCacheElement sealed : System::Configuration::ConfigurationElement
public sealed class MemoryCacheElement : System.Configuration.ConfigurationElement
type MemoryCacheElement = class
inherit ConfigurationElement
Public NotInheritable Class MemoryCacheElement
Inherits ConfigurationElement
- 继承
注解
该 MemoryCacheElement 类定义 memoryCache 可用于配置缓存的元素。 可以在单个应用程序中使用类的 MemoryCache 多个实例。
memoryCache配置文件中的每个元素都可以包含命名MemoryCache实例的设置。
该 memoryCache 元素需要子 namedCaches 元素。 若要定义缓存的命名配置以及默认配置,可以添加 namedCaches 元素。 有关如何添加命名缓存配置的详细信息,请参阅 <namedCaches> 元素(缓存设置)。
构造函数
| 名称 | 说明 |
|---|---|
| MemoryCacheElement(String) |
初始化 MemoryCacheElement 类的新实例。 |