Method SetSlidingExpiration
SetSlidingExpiration(TimeSpan)
Sets the sliding expiration time of the cache item. Only one type of expiration, either absolute or sliding expiration can be configured at one time.
Declaration
public void SetSlidingExpiration(TimeSpan timespan)
Parameters
Type | Name | Description |
---|---|---|
TimeSpan | timespan | The time span where if the item is not accessed it will be expired from the cache. |