using System; using System.Collections; namespace FrostFS.SDK.ClientV2; internal struct SessionCache(ulong sessionExpirationDuration) { internal Hashtable Cache { get; } = []; internal ulong CurrentEpoch { get; set; } internal ulong TokenDuration { get; set; } = sessionExpirationDuration; internal void DeleteByPrefix(string prefix) { foreach (var key in Cache.Keys) { if (((string)key).StartsWith(prefix, StringComparison.Ordinal)) { Cache.Remove(key); } } } }