package com.ruoyi.monitor.domain;

import java.math.BigDecimal;
import java.util.Date;

import javax.validation.constraints.DecimalMax;
import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotNull;

import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 系统监控对象 dc_system_monitor
 * 
 * @author ruoyi
 * @date 2025-12-17
 */
public class SystemMonitor extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 监控ID */
    private Long monitorId;

    /** 监控时间 */
    @Excel(name = "监控时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @NotNull(message = "监控时间不能为空")
    private Date monitorTime;

    /** CPU使用率 */
    @Excel(name = "CPU使用率")
    @DecimalMin(value = "0.00", message = "CPU使用率不能为负数")
    @DecimalMax(value = "100.00", message = "CPU使用率不能超过100")
    private BigDecimal cpuUsage;

    /** 内存使用率 */
    @Excel(name = "内存使用率")
    @DecimalMin(value = "0.00", message = "内存使用率不能为负数")
    @DecimalMax(value = "100.00", message = "内存使用率不能超过100")
    private BigDecimal memoryUsage;

    /** 磁盘使用率 */
    @Excel(name = "磁盘使用率")
    @DecimalMin(value = "0.00", message = "磁盘使用率不能为负数")
    @DecimalMax(value = "100.00", message = "磁盘使用率不能超过100")
    private BigDecimal diskUsage;

    /** 网络入流量 */
    @Excel(name = "网络入流量")
    private Long networkIn;

    /** 网络出流量 */
    @Excel(name = "网络出流量")
    private Long networkOut;

    /** 活跃连接数 */
    @Excel(name = "活跃连接数")
    private Integer activeConnections;

    /** 线程数 */
    @Excel(name = "线程数")
    private Integer threadCount;

    /** 堆内存使用量 */
    @Excel(name = "堆内存使用量")
    private Long heapMemoryUsed;

    /** 堆内存最大值 */
    @Excel(name = "堆内存最大值")
    private Long heapMemoryMax;

    /** GC次数 */
    @Excel(name = "GC次数")
    private Long gcCount;

    /** GC时间 */
    @Excel(name = "GC时间")
    private Long gcTime;

    public void setMonitorId(Long monitorId) 
    {
        this.monitorId = monitorId;
    }

    public Long getMonitorId() 
    {
        return monitorId;
    }
    public void setMonitorTime(Date monitorTime) 
    {
        this.monitorTime = monitorTime;
    }

    public Date getMonitorTime() 
    {
        return monitorTime;
    }
    public void setCpuUsage(BigDecimal cpuUsage) 
    {
        this.cpuUsage = cpuUsage;
    }

    public BigDecimal getCpuUsage() 
    {
        return cpuUsage;
    }
    public void setMemoryUsage(BigDecimal memoryUsage) 
    {
        this.memoryUsage = memoryUsage;
    }

    public BigDecimal getMemoryUsage() 
    {
        return memoryUsage;
    }
    public void setDiskUsage(BigDecimal diskUsage) 
    {
        this.diskUsage = diskUsage;
    }

    public BigDecimal getDiskUsage() 
    {
        return diskUsage;
    }
    public void setNetworkIn(Long networkIn) 
    {
        this.networkIn = networkIn;
    }

    public Long getNetworkIn() 
    {
        return networkIn;
    }
    public void setNetworkOut(Long networkOut) 
    {
        this.networkOut = networkOut;
    }

    public Long getNetworkOut() 
    {
        return networkOut;
    }
    public void setActiveConnections(Integer activeConnections) 
    {
        this.activeConnections = activeConnections;
    }

    public Integer getActiveConnections() 
    {
        return activeConnections;
    }
    public void setThreadCount(Integer threadCount) 
    {
        this.threadCount = threadCount;
    }

    public Integer getThreadCount() 
    {
        return threadCount;
    }
    public void setHeapMemoryUsed(Long heapMemoryUsed) 
    {
        this.heapMemoryUsed = heapMemoryUsed;
    }

    public Long getHeapMemoryUsed() 
    {
        return heapMemoryUsed;
    }
    public void setHeapMemoryMax(Long heapMemoryMax) 
    {
        this.heapMemoryMax = heapMemoryMax;
    }

    public Long getHeapMemoryMax() 
    {
        return heapMemoryMax;
    }
    public void setGcCount(Long gcCount) 
    {
        this.gcCount = gcCount;
    }

    public Long getGcCount() 
    {
        return gcCount;
    }
    public void setGcTime(Long gcTime) 
    {
        this.gcTime = gcTime;
    }

    public Long getGcTime() 
    {
        return gcTime;
    }

    @Override
    public String toString() {
        return "SystemMonitor{" +
                "monitorId=" + monitorId +
                ", monitorTime=" + monitorTime +
                ", cpuUsage=" + cpuUsage +
                ", memoryUsage=" + memoryUsage +
                ", diskUsage=" + diskUsage +
                ", networkIn=" + networkIn +
                ", networkOut=" + networkOut +
                ", activeConnections=" + activeConnections +
                ", threadCount=" + threadCount +
                ", heapMemoryUsed=" + heapMemoryUsed +
                ", heapMemoryMax=" + heapMemoryMax +
                ", gcCount=" + gcCount +
                ", gcTime=" + gcTime +
                '}';
    }
}