IPageCacheBuilderTPageTypeExpiration Method |
Sets the expiration of the cached data.
Namespace: Kentico.Content.Web.MvcAssembly: Kentico.Content.Web.Mvc (in Kentico.Content.Web.Mvc.dll) Version: 13.0.131
Syntax IPageCacheBuilder<TPageType> Expiration(
TimeSpan expiration,
bool useSliding = false
)
Parameters
- expiration
- Type: SystemTimeSpan
Expiration time span. - useSliding (Optional)
- Type: SystemBoolean
Indicates if the sliding expiration should be used.
Return Value
Type:
IPageCacheBuilderTPageTypeRemarks
If the expiration is not configured the configuration of content cache minutes from site settings is used automatically.
If multiple expiration provided the value of the last one configured is used.
See Also