Establishes a relationship between an item stored in an application's Cache object and either a specific database table. This class cannot be inherited.

Namespace: Alachisoft.NCache.Runtime.Dependencies
Assembly: Alachisoft.NCache.Runtime (in Alachisoft.NCache.Runtime.dll) Version: 4.3.0.0 (4.3.0.0)

Syntax

C#
[SerializableAttribute]
public sealed class DBCacheDependency : CacheDependency
Visual Basic
<SerializableAttribute>
Public NotInheritable Class DBCacheDependency
	Inherits CacheDependency
Visual C++
[SerializableAttribute]
public ref class DBCacheDependency sealed : public CacheDependency

Remarks

This Feature is Not Available in Express You can add items with dependencies to your application's cache with the [!:Cache.Add] and Insert methods.

When you add an item to an application's [!:Cache] object with DBCacheDependency, it monitors a specific database table so that when the table changes, items associated with the table will be automatically removed from the Cache. This helps you avoid losing changes made to the object between the time it is created and the time it is inserted into the [!:Cache].

Inheritance Hierarchy

System..::..Object
  Alachisoft.NCache.Runtime.Dependencies..::..CacheDependency
    Alachisoft.NCache.Runtime.Dependencies..::..DBCacheDependency

See Also