DataCachePut Method (String, Object, TimeSpan, IEnumerableDataCacheTag, String)Windows Server AppFabric Caching Compatibility Library
Adds or replaces an object in the region with a specified object timeout.

Namespace: Soss.Compat.WSAF
Assembly: soss_wsaf_compat (in soss_wsaf_compat.dll) Version: 1.1.0.100 (1.1.0.100)
Syntax

public DataCacheItemVersion Put(
	string key,
	Object value,
	TimeSpan timeout,
	IEnumerable<DataCacheTag> tags,
	string region
)

Parameters

key
Type: SystemString
The unique identifier used to access the object in the cache.
value
Type: SystemObject
The object to add or replace in the cache.
timeout
Type: SystemTimeSpan
The amount of time that the object should reside in the cache before expiration. The timeout parameter is ignored if object already exists.
tags
Type: System.Collections.GenericIEnumerableDataCacheTag
List of DataCacheTag objects associated with the cached object.
region
Type: SystemString
The name of the region where the object will be stored.

Return Value

Type: DataCacheItemVersion
The DataCacheItemVersion object representing the version of the object after the Put operation completes, or null if there is a version mismatch.
Exceptions

ExceptionCondition
DataCacheExceptionthrown if the WSAF Caching Compatibility Library is used with ScaleOut StateServer older than version 5.3 and object to update does not exist in the cache.
Remarks

This overload can be used for updating the tags associated with the object.

See Also

Reference