From 8dd5c057222ea4f6d22d6bc3fba468600f14a330 Mon Sep 17 00:00:00 2001 From: huanghongfa <huanghongfa123456> Date: 星期二, 28 十二月 2021 16:28:27 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/utlis/AssemblyUtils.java | 15 --------------- 1 files changed, 0 insertions(+), 15 deletions(-) diff --git a/springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/utlis/AssemblyUtils.java b/springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/utlis/AssemblyUtils.java index 23f59d4..0f9c8fb 100644 --- a/springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/utlis/AssemblyUtils.java +++ b/springcloud_k8s_panzhihuazhihuishequ/common/src/main/java/com/panzhihua/common/utlis/AssemblyUtils.java @@ -2,7 +2,6 @@ import com.panzhihua.common.model.vos.community.ComActQuestnaireAnswerContentVO; import lombok.extern.slf4j.Slf4j; -import org.apache.commons.io.FileUtils; import javax.imageio.ImageIO; import javax.xml.bind.DatatypeConverter; @@ -179,19 +178,5 @@ resultList.add(userData); } return resultList; - } - - public static File createTmpFile(InputStream inputStream, String name, String ext, File tmpDirFile) throws IOException { - File resultFile = File.createTempFile(name, '.' + ext, tmpDirFile); - resultFile.deleteOnExit(); - FileUtils.copyToFile(inputStream, resultFile); - return resultFile; - } - - public static File bytesToFile(byte[] bytes, String fileType) throws IOException { - return createTmpFile(new ByteArrayInputStream(bytes), - UUID.randomUUID().toString(), - fileType, - Files.createTempDirectory("tempFile").toFile()); } } -- Gitblit v1.7.1