Class CacheableObjectResultExtensions
- Namespace
- Cuemon.Extensions.AspNetCore.Mvc
- Assembly
- Cuemon.Extensions.AspNetCore.Mvc.dll
Extension methods for the ICacheableObjectResult interface.
public static class CacheableObjectResultExtensions
- Inheritance
-
CacheableObjectResultExtensions
Methods
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
instance
TThe instance to make cacheable.
setup
Action<CacheableObjectResultOptions<T>>The CacheableObjectResultOptions<T> that needs to be configured.
Returns
- ICacheableObjectResult
An ICacheableObjectResult implementation.
Type Parameters
T
The type of the object to make cacheable.
- See Also
-
Cuemon.AspNetCore.Mvc.CacheableObjectResult`1
WithEntityTagHeader<T>(T, Action<ContentBasedObjectResultOptions<T>>)
Encapsulates the specified instance
within an integrity based object that is processed by an HTTP ETag filter implementation.
public static ICacheableObjectResult WithEntityTagHeader<T>(this T instance, Action<ContentBasedObjectResultOptions<T>> setup)
Parameters
instance
TThe instance to make cacheable.
setup
Action<ContentBasedObjectResultOptions<T>>The ContentBasedObjectResultOptions<T> that needs to be configured.
Returns
- ICacheableObjectResult
An ICacheableObjectResult implementation.
Type Parameters
T
The type of the object to make cacheable.
- See Also
-
Cuemon.AspNetCore.Mvc.CacheableObjectResult`1
WithLastModifiedHeader<T>(T, Action<TimeBasedObjectResultOptions<T>>)
Encapsulates the specified instance
within a timestamp based object that is processed by a Last-Modified filter implementation.
public static ICacheableObjectResult WithLastModifiedHeader<T>(this T instance, Action<TimeBasedObjectResultOptions<T>> setup)
Parameters
instance
TThe instance to make cacheable.
setup
Action<TimeBasedObjectResultOptions<T>>The TimeBasedObjectResultOptions<T> that needs to be configured.
Returns
- ICacheableObjectResult
An ICacheableObjectResult implementation.
Type Parameters
T
The type of the object to make cacheable.
- See Also
-
Cuemon.AspNetCore.Mvc.CacheableObjectResult`1