摘要: 需求:使用一些图片和用户输入的文案合成图片或者海报 使用三方库 mvn管理 <!--图片处理 start --> <dependency> <groupId>com.twelvemonkeys.imageio</groupId> <artifactId>imageio-jpeg</artifactI 阅读全文
posted @ 2020-11-16 14:58 fatetop 阅读(1329) 评论(0) 推荐(0) 编辑
摘要: 使用barcode4j条形码生成, mvn管理 <!-- 条形码 --> <dependency> <groupId>net.sf.barcode4j</groupId> <artifactId>barcode4j-light</artifactId> <version>2.0</version> 阅读全文
posted @ 2020-11-16 13:49 fatetop 阅读(804) 评论(0) 推荐(0) 编辑
摘要: javax.imageio.IIOException: Unsupported Image Type at com.sun.imageio.plugins.jpeg.JPEGImageReader.readInternal(JPEGImageReader.java:1079) at com.sun. 阅读全文
posted @ 2020-11-09 17:07 fatetop 阅读(855) 评论(0) 推荐(0) 编辑
摘要: java默认都是同步的操作,但是有些操作需要大量耗时,可以进行异步处理 import java.util.concurrent.CompletableFuture; CompletableFuture.runAsync(() -> { // do something } 阅读全文
posted @ 2020-11-03 09:31 fatetop 阅读(477) 评论(0) 推荐(0) 编辑
摘要: 1、使用 new URL() ImageIO.read(new URL(url)); 获取图片有限制,可以读取图片的格式 :[BMP, bmp, jpg, JPG, wbmp, jpeg, png, PNG, JPEG, WBMP, GIF, gif] 获取不到图片时返回为null,后续操作可能会报 阅读全文
posted @ 2020-11-02 15:57 fatetop 阅读(4691) 评论(0) 推荐(0) 编辑