java8
果果篮
这个作者很懒,什么都没留下…
展开
-
动态代理一个类中的指定方法,及代码中如何使用
1、代理:MyHttpServletRequest 代理HttpServletRequestimport org.springframework.beans.factory.annotation.Value;import javax.servlet.http.HttpServletRequest;import java.lang.reflect.InvocationHandler;import java.lang.reflect.Method;import java.lang.refl...原创 2021-05-17 09:25:56 · 562 阅读 · 0 评论 -
springboot 集成 ureport2 报错
根据网上教程 集成ureport项目启动时报错。原因:Ureport2 需要加载的配置文件,不需要单独写成配置文件再去加载,直接写到application.yml中ureport: disableHttpSessionReportCache: false disableFileProvider: false fileStoreDir: D:/ureportfiles debug: true启动类上再加上@SpringBootApplication@ImportRes..原创 2021-05-13 16:53:45 · 1137 阅读 · 1 评论 -
java list 根据对象某些字段去重
根据DeptType、UserPosition 两个属性去重list.stream().collect(Collectors.collectingAndThen(Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(o -> o.getDeptType() + ";" + o.getUserPosition()))), ArrayList::new));...原创 2021-03-12 09:19:26 · 498 阅读 · 0 评论