using System.ComponentModel.DataAnnotations;

namespace Watcher.ViewModels
{
    public class EditServerViewModel
    {
        public int Id { get; set; }

        [Required(ErrorMessage = "Name ist erforderlich")]
        public string? Name { get; set; }

        [Required(ErrorMessage = "IP-Adresse ist erforderlich")]
        [RegularExpression(@"^(?:[0-9]{1,3}\.){3}[0-9]{1,3}$", ErrorMessage = "Ungültige IP-Adresse")]
        public required string IPAddress { get; set; }

        [Required(ErrorMessage = "Typ ist erforderlich")]
        public string? Type { get; set; }

        // Hardware Measurment Warning/Crit Values
        public double CPU_Load_Warning { get; set; } = 75.0;
        public double CPU_Load_Critical { get; set; } = 90.0;
        public double CPU_Temp_Warning { get; set; } = 80.0;
        public double CPU_Temp_Critical { get; set; } = 90.0;

        public double RAM_Load_Warning { get; set; } = 85.0;
        public double RAM_Load_Critical { get; set; } = 95.0;

        public double GPU_Load_Warning { get; set; } = 75.0;
        public double GPU_Load_Critical { get; set; } = 90.0;
        public double GPU_Temp_Warning { get; set; } = 70.0;
        public double GPU_Temp_Critical { get; set; } = 80.0;

        public double Disk_Usage_Warning { get; set; } = 75.0;
        public double Disk_Usage_Critical { get; set; } = 90.0;
        public double DISK_Temp_Warning { get; set; } = 34.0;
        public double DISK_Temp_Critical { get; set; } = 36.0;
    }
}