MemoryCacheElement::Name Property

.NET Framework (current version)
 

Gets or sets the name of a particular cache configuration.

Namespace:   System.Runtime.Caching.Configuration
Assembly:  System.Runtime.Caching (in System.Runtime.Caching.dll)

public:
[ConfigurationPropertyAttribute("name", DefaultValue = "", IsRequired = true, 
	IsKey = true)]
[TypeConverterAttribute((WhiteSpaceTrimStringConverter^::typeid))]
[StringValidatorAttribute(MinLength = 1)]
property String^ Name {
	String^ get();
	void set(String^ value);
}

Property Value

Type: System::String^

The name of a cache configuration.

The Name property value is the unique identifier for a particular named cache configuration. Each cache configuration must have a unique ID.

In the memoryCache section of a configuration file, a unique cache configuration is defined by a namedCaches configuration collection. Each named cache entry requires a unique name in the configuration file. This value must be at least one character long.

For more information about how to configure the cache, see <namedCaches> Element (Cache Settings).

.NET Framework
Available since 4.0
Return to top
Show: