mirror of
https://github.com/nsnail/NetAdmin.git
synced 2025-08-03 02:18:00 +08:00
* chore: 🔨 css 基础单位 [skip ci] * fix: 🐛 ca2263 System.Enum.GetValues<TEnum>() [skip ci] * feat: ✨ 前端表格高级筛选 [skip ci]
53 lines
1.3 KiB
C#
53 lines
1.3 KiB
C#
namespace NetAdmin.Domain.Dto.Sys.Cache;
|
|
|
|
/// <summary>
|
|
/// 响应:获取所有缓存项
|
|
/// </summary>
|
|
public sealed record GetAllEntriesRsp : DataAbstraction
|
|
{
|
|
/// <summary>
|
|
/// Initializes a new instance of the <see cref="GetAllEntriesRsp" /> class.
|
|
/// </summary>
|
|
public GetAllEntriesRsp() { }
|
|
|
|
/// <summary>
|
|
/// Initializes a new instance of the <see cref="GetAllEntriesRsp" /> class.
|
|
/// </summary>
|
|
public GetAllEntriesRsp(long absExp, string key, long sldExp, string data)
|
|
{
|
|
AbsExp = absExp;
|
|
Key = key;
|
|
SldExp = sldExp;
|
|
Data = data;
|
|
}
|
|
|
|
/// <summary>
|
|
/// 绝对过期时间
|
|
/// </summary>
|
|
public DateTime? AbsExpTime => AbsExp == -1 ? null : DateTime.FromBinary(AbsExp).ToLocalTime();
|
|
|
|
/// <summary>
|
|
/// 滑动过期时间
|
|
/// </summary>
|
|
public DateTime? SldExpTime => SldExp == -1 ? null : DateTime.FromBinary(SldExp).ToLocalTime();
|
|
|
|
/// <summary>
|
|
/// 绝对过期时间
|
|
/// </summary>
|
|
public long AbsExp { get; init; }
|
|
|
|
/// <summary>
|
|
/// 缓存值
|
|
/// </summary>
|
|
public string Data { get; init; }
|
|
|
|
/// <summary>
|
|
/// 缓存键
|
|
/// </summary>
|
|
public string Key { get; init; }
|
|
|
|
/// <summary>
|
|
/// 滑动过期时间
|
|
/// </summary>
|
|
public long SldExp { get; init; }
|
|
} |