Export (0) Print
Expand All

ObjectCache.Set Method

When overridden in a derived class, inserts a cache entry into the cache.

This member is overloaded. For complete information about this member, including syntax, usage, and examples, click a name in the overload list.

  Name Description
Public method Set(CacheItem, CacheItemPolicy) When overridden in a derived class, inserts the cache entry into the cache as a CacheItem instance, specifying information about how the entry will be evicted.
Public method Set(String, Object, DateTimeOffset, String) When overridden in a derived class, inserts a cache entry into the cache, specifying time-based expiration details.
Public method Set(String, Object, CacheItemPolicy, String) When overridden in a derived class, inserts a cache entry into the cache.
Top

The typical behavior of the Set overload methods is an insert-or-update operation. A cache entry is either inserted as a new entry if the specified entry does not exist, or the cache entry is updated with a new value if it already exists.

Show:
© 2014 Microsoft