/* * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * Neither the name of the dreamlu.net developer nor the names of its * contributors may be used to endorse or promote products derived from * this software without specific prior written permission. * Author: Chill 庄骞 (smallchill@163.com) */ package org.sxkj.resource.service; import com.baomidou.mybatisplus.core.metadata.IPage; import org.apache.ibatis.annotations.Param; import org.springblade.core.mp.base.BaseService; import org.sxkj.common.model.ResponseResult; import org.sxkj.resource.dto.WaylineJobInfoQueryParam; import org.sxkj.resource.entity.Attach; import org.sxkj.resource.param.AttachPageParam; import org.sxkj.resource.vo.*; import org.sxkj.system.vo.TreeVo; import java.io.IOException; import java.util.Date; import java.util.List; import java.util.Map; /** * 附件表 服务类 * * @author Chill */ public interface IAttachService extends BaseService { /** * 自定义分页 * * @param page * @param attach * @return */ IPage selectAttachPage(IPage page, AttachPageParam attach); /** * ai图片 * @param page * @param attach * @return */ public IPage findAttachImages(IPage page, AttachVO attach); /** * ai数据 * * @param page * @param attach * @return */ public List findAiAttachImages(IPage page, AttachVO attach); /** * 查询经纬度数据 * @param eventRecordIds * @return */ List findAiEventMd5s(List eventRecordIds) ; List getDeptAllSize(String startTime,String endTime); /** * 保存附件表信息 * @param attach 附件表信息 * @return */ Boolean saveAttachInfo(Attach attach); /** * 删除 附件表及对应的附件信息 * @param ids * @return */ Boolean removeBatchAndDataByIds(List ids); /** * 根据附件ID集合获取去除 cloud-bucket 前缀后的 name 列表 * * @param ids 附件ID集合 * @return 处理后的 name 列表 */ List getAttachNames(List ids); /** * 历史正射图片处理 * @return */ Boolean hisOrtPicHandler(); /** * 查询媒体属性根据图片,名称 * * @param names * @return */ public Map findMetaDataByName(@Param("names") List names) ; void saveMd5(); /** * 获取地图上事件位置及数量 * * @param dto 参数 * @return list */ public TreeVo mapAttachEvents(AttachQueryParam dto) ; int updateFileName(Long id, String nickName); public void deletedNotExistsUrl(); /** * 获取附件详情 * @param id * @return */ AttachInfoVO getAttachInfo(Long id); /** * 根据任务ID获取附件详情 * @param jobId * @return */ List getAttachInfoByJobId(String jobId); /** * 查询成果数量 * @param jobId 任务id * @return 成果数量 */ public Long findResultNumByJobId(String jobId); /** * 批量删除媒体文件 * @param ids * @return */ int deleteMediaFile(List ids); /** * * @param attachStatisticsVo * @return */ List attachTypeStatistics(AttachStatisticsVo attachStatisticsVo); /** * 通过md5获取附件对象 * @param md5 * @return */ default Attach getAttachByMd5(String md5) { return null; } /** * 查询昨日上传的附件信息 * @param resultType * 成果类型:0图片,1=视频,2=ai,3=三维, * 4=正射,5=全景, 6=图片压缩小(后缀small), * 7=图片压缩中(后缀show),8视频一帧图,9视频压缩, * 10ai压缩小,11ai压缩中 * @return list */ List findAttachInfoByYesterday(int resultType, Date startTime, Date endTime); /** * * @param param * @return */ List getManageAttachTypeStatistics(WaylineJobInfoQueryParam param); /** * 删除设备下的所有文件 * @param deviceSn * @param timestamp * @param operator * @param workspaceId * @return */ Boolean deleteAttach(String deviceSn, long timestamp, Long operator, String workspaceId); /** * 获取图斑图片 * @param lotInfoId * @return */ List getlotInfoList(Long lotInfoId); /** * 统计三维面积 * @param deviceSn * @param startDate * @param endDate * @param resultTypes * @return */ List calculateTheThreeDimensionalArea(String deviceSn, String startDate, String endDate, String resultTypes, String areaCode); /** * 流式附件下载 * @param param 下载参数 * @param outputStream 输出流 * @return 处理结果 * @throws IOException IO异常 */ Boolean downloadByByte(String param, java.io.OutputStream outputStream) throws IOException; }