随笔分类 -  工具类

摘要:统一返回值,Result import java.io.Serializable; import java.util.List; import java.util.Optional; import org.springframework.http.HttpStatus; import org.spr 阅读全文
posted @ 2022-05-27 11:23 满Sir 阅读(202) 评论(0) 推荐(0) 编辑
摘要:方式1:简单明了 jar包依赖: <dependency> <groupId>org.apache.httpcomponents</groupId> <artifactId>httpcore</artifactId> <version>4.4.9</version> </dependency> <d 阅读全文
posted @ 2022-05-27 11:20 满Sir 阅读(779) 评论(0) 推荐(0) 编辑
摘要:1. 配置RestTemplate import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springfr 阅读全文
posted @ 2022-04-06 15:48 满Sir 阅读(182) 评论(0) 推荐(0) 编辑
摘要:转自: https://blog.csdn.net/u014676619/article/details/49624165 import java.io.BufferedReader; import java.io.InputStream; import java.io.InputStreamRea 阅读全文
posted @ 2021-12-09 09:52 满Sir 阅读(746) 评论(0) 推荐(0) 编辑
摘要:创建返回状态码枚举 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 package com.sunny.tool.api.enums; /** * @Author sunt * @Des 阅读全文
posted @ 2021-12-09 09:07 满Sir 阅读(1038) 评论(0) 推荐(0) 编辑
摘要:代码: import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.redis.core.RedisTemplate; import org.springframewor 阅读全文
posted @ 2021-12-06 09:50 满Sir 阅读(101) 评论(0) 推荐(0) 编辑
摘要:* 集合操作常用方法类. * <p> * * @author 柯 */ public class ListUtil { /** * 判断List不为空,非空返回true,空则返回false * * @param list * @return boolean */ public static bool 阅读全文
posted @ 2021-12-06 09:17 满Sir 阅读(255) 评论(0) 推荐(0) 编辑
摘要:ArithUtil: /** * 如果需要精确计算,非要用String来够造BigDecimal不可 */ package com.leaniot.securitymonitor.util; import java.math.BigDecimal; /** * 由于Java的简单类型不能够精确的对浮 阅读全文
posted @ 2021-12-03 16:43 满Sir 阅读(147) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示