package com.gk.hotwork.Service; import com.gk.hotwork.Domain.AttachmentInfo; import com.gk.hotwork.Domain.Exception.BusinessException; import com.gk.hotwork.Domain.UserInfo; import org.apache.commons.collections4.CollectionUtils; import org.springframework.web.multipart.MultipartFile; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.util.List; /** * @email 1603559716@qq.com * @author: zf * @date: 2023/7/24 * @time: 13:53 */ public interface AttachmentService { AttachmentInfo findByKey(String key); AttachmentInfo findById(Long id); List findByIds(List ids); List findByBusinessId(Long businessId); void delete(Long id, UserInfo userInfo); Object saveFileToPath(MultipartFile file, String module, int type, UserInfo user); Object saveBatchFileToPath(MultipartFile[] file, String module, UserInfo user); void downloadForStream(HttpServletResponse response, String key); void downloadById(HttpServletResponse response, HttpServletRequest request, Long id); }