package com.muyu.domain.resp;

import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.SuperBuilder;

import java.util.List;

/**
 * 故障规则数据总数响应对象
 * @Author：weiran
 * @Package：com.muyu.cloud.faultmanage.domain.resp
 * @Project：cloud-server-8
 * @name：FaultConditionTotalListResp
 * @Date：2024/9/21 20:00
 */

@Data
@SuperBuilder
@AllArgsConstructor
@NoArgsConstructor
@Tag(name="故障规则数据总数列表",description = "数据和总数的响应")
public class FaultConditionTotalListResp {

    /**
     * 故障规则信息集合
     */
    private List<FaultConditionListResp> faultConditionListRespList;

    /**
     * 总数量
     */
    private  long total;

    /**
     *
     * @param faultConditionListRespList
     * @param total
     * @return
     */
    public static FaultConditionTotalListResp faultConditionTotalListResp(List<FaultConditionListResp> faultConditionListRespList,long total){
        FaultConditionTotalListResp faultConditionTotalListResp = new FaultConditionTotalListResp();
        faultConditionTotalListResp.setFaultConditionListRespList(faultConditionListRespList);
        faultConditionTotalListResp.setTotal(total);
        return faultConditionTotalListResp;
    }
}
