using System; namespace Best.HTTP.Caching { /// /// Represents the configuration options for the HTTP cache. /// public sealed class HTTPCacheOptions { /// /// Gets or sets the maximum duration for which cached entries will be retained. /// public TimeSpan DeleteOlder { get; internal set; } = TimeSpan.MaxValue; /// /// Gets or sets the maximum size, in bytes, that the cache can reach. /// public ulong MaxCacheSize { get; internal set; } = 512 * 1024 * 1024; /// /// Initializes a new instance of the class with default settings. /// public HTTPCacheOptions() { // Default constructor with no arguments. } /// /// Initializes a new instance of the class with custom settings. /// /// The maximum age for cached entries to be retained. /// The maximum size, in bytes, that the cache can reach. public HTTPCacheOptions(TimeSpan deleteOlder, ulong maxCacheSize) { this.DeleteOlder = deleteOlder; this.MaxCacheSize = maxCacheSize; } } }