using System;

namespace XP.Hardware.RaySource.Comet
{
    /// <summary>
    /// Comet 射线源状态数据
    /// 与 .NET 8 层的 SystemStatusData 字段一一对应
    /// 仅使用 .NET Framework 4.8 兼容的基础类型，不依赖任何 .NET 8 特有类型
    /// </summary>
    public class CometStatusData
    {
        /// <summary>
        /// 设定电压值（kV）
        /// </summary>
        public float SetVoltage { get; set; }

        /// <summary>
        /// 实际电压值（kV）
        /// </summary>
        public float ActualVoltage { get; set; }

        /// <summary>
        /// 设定电流值（μA）
        /// </summary>
        public float SetCurrent { get; set; }

        /// <summary>
        /// 实际电流值（μA）
        /// </summary>
        public float ActualCurrent { get; set; }

        /// <summary>
        /// 射线开启状态
        /// </summary>
        public bool IsXRayOn { get; set; }

        /// <summary>
        /// 暖机状态描述
        /// </summary>
        public string WarmUpStatus { get; set; }

        /// <summary>
        /// 真空状态描述
        /// </summary>
        public string VacuumStatus { get; set; }

        /// <summary>
        /// 启动状态描述
        /// </summary>
        public string StartUpStatus { get; set; }

        /// <summary>
        /// 自动定心状态描述
        /// </summary>
        public string AutoCenterStatus { get; set; }

        /// <summary>
        /// 灯丝调整状态描述
        /// </summary>
        public string FilamentAdjustStatus { get; set; }

        /// <summary>
        /// 连锁状态
        /// </summary>
        public bool IsInterlockActive { get; set; }

        /// <summary>
        /// 看门狗状态
        /// </summary>
        public string WatchdogStatus { get; set; }

        /// <summary>
        /// 功率模式
        /// </summary>
        public string PowerMode { get; set; }

        /// <summary>
        /// TXI 状态
        /// </summary>
        public string TxiStatus { get; set; }

        /// <summary>
        /// 时间戳
        /// </summary>
        public DateTime Timestamp { get; set; } = DateTime.Now;
    }
}
