WithCacheableHeaders Method
Definition
- Namespace
- Cuemon.Extensions.AspNetCore.Mvc
- Assemblies
- Cuemon.Extensions.AspNetCore.Mvc.dll
WithCacheableHeaders<T>(T, Action<CacheableObjectResultOptions<T>>)
Encapsulates the specified instance within a timestamp and integrity based object that is processed by both HTTP Last-Modified and HTTP ETag filters implementation.
public static ICacheableObjectResult WithCacheableHeaders<T>(this T instance, Action<CacheableObjectResultOptions<T>> setup)
Parameters
instanceTThe instance to make cacheable.
setupAction<CacheableObjectResultOptions<T>>The CacheableObjectResultOptions<T> that needs to be configured.
Returns
- ICacheableObjectResult
An ICacheableObjectResult implementation.
Type Parameters
TThe type of the object to make cacheable.
- See Also
-
CacheableObjectResult<T>