package com.huatek.busi.service;

import java.math.BigDecimal;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.Date;

import com.huatek.busi.vo.BusiSensorVo;

/**
 * 数据缺失率 Service
 *
 * @author anker_cheng
 * @date Jul 15, 2019 3:43:31 PM
 */
public interface FailureRateService {
    /**
     * 保存传感器缺失率
     * 
     * @param sensor
     *            传感器
     * @param date
     *            日期
     * @param uploadCycle
     *            上传周期(分钟)
     * @param dataCount
     *            数据总数
     */
    void saveSensorFailureRate(BusiSensorVo sensor, LocalDate date, BigDecimal uploadCycle, Integer dataCount);

    String getSensorLossRate(String sensorCode, LocalDateTime startTime, LocalDateTime endTime);

    String getSensorLossRate(String sensorCode, Date startTime, Date endTime);
}
