Add dependency to the cache item.

Namespace: Alachisoft.NCache.Web.Caching
Assembly: Alachisoft.NCache.Web (in Alachisoft.NCache.Web.dll) Version: 4.3.0.0 (4.3.0.0)

Syntax

C#
public override bool AddDependency(
	string key,
	CacheDependency dependency,
	bool isResyncRequired
)
Visual Basic
Public Overrides Function AddDependency ( 
	key As String,
	dependency As CacheDependency,
	isResyncRequired As Boolean
) As Boolean
Visual C++
public:
virtual bool AddDependency(
	String^ key, 
	CacheDependency^ dependency, 
	bool isResyncRequired
) override

Parameters

key
Type: System..::..String
key used to reference the required object
dependency
Type: Alachisoft.NCache.Runtime.Dependencies..::..CacheDependency
CacheDependency to be added
isResyncRequired
Type: System..::..Boolean
If set, then at the time of expiration, a fresh copy of the item is fetched from the master datasource provided that the read-thru is enabled. Otherwise it is expired as normal.

Return Value

Type: Boolean
True if the operation successeded otherwise false

See Also