DynamicCacheBustingOptions Class
Definition
- Namespace
- Cuemon.AspNetCore.Configuration
- Assemblies
- Cuemon.AspNetCore.dll
Specifies options that is related to DynamicCacheBusting operations.
public class DynamicCacheBustingOptions : CacheBustingOptions, IParameterObject
- Inheritance
-
objectDynamicCacheBustingOptions
- Implements
- Inherited Members
Examples
The following example demonstrates configuration options for dynamic cache busting.
using System;
using Cuemon.Configuration;
using Microsoft.Extensions.Options;
namespace Cuemon.AspNetCore.Configuration;
public static class DynamicCacheBustingOptionsExample
{
public static void Demonstrate()
{
var options = new DynamicCacheBustingOptions
{
PreferredCasing = CasingMethod.UpperCase,
PreferredLength = 6,
TimeToLive = TimeSpan.FromMinutes(5)
};
var cacheBusting = new DynamicCacheBusting(Options.Create(options));
Console.WriteLine(cacheBusting.Version);
}
}
Constructors
| Name | Description |
|---|---|
| DynamicCacheBustingOptions() | Initializes a new instance of the DynamicCacheBustingOptions class. |
Properties
| Name | Description |
|---|---|
| PreferredCharacters | Gets or sets the preferred characters of Version. |
| PreferredLength | Gets or sets the preferred length of Version. |
| TimeToLive | Gets or sets the TTL of Version. |