随笔分类 -  java

上一页 1 ··· 6 7 8 9 10 11 下一页
摘要:public interface ExecutorServerBase { default RuleResult getUserList(RuleParam rule) { RuleResult result = new RuleResult(); List<String> userIdList = 阅读全文
posted @ 2020-09-16 17:32 八英里 阅读(4094) 评论(0) 推荐(0)
摘要:假如我有一个数组: ArrayList<Integer> mArrayList = new ArrayList<Integer>(); mArrayList.add(0); mArrayList.add(1); mArrayList.add(2); mArrayList.add(3); 我需要从中随 阅读全文
posted @ 2020-09-07 10:20 八英里 阅读(1349) 评论(0) 推荐(0)
摘要:jvisualvm.exe https://fastthread.io/ 阅读全文
posted @ 2020-08-31 11:30 八英里 阅读(326) 评论(0) 推荐(0)
摘要:import org.springframework.util.CollectionUtils; CollectionUtils.isEmpty(certificateHasUsers) 阅读全文
posted @ 2020-07-09 10:37 八英里 阅读(931) 评论(0) 推荐(0)
摘要:5 3 I am getting this warning on Sonar: Avoid using implementation types like 'HashMap'; use the interface instead What does it mean? The class in whi 阅读全文
posted @ 2020-06-16 14:42 八英里 阅读(791) 评论(0) 推荐(0)
摘要:import java.util.Collections; yphlLin.set(index, null); //移除List中所有null yphlLin.removeAll(Collections.singleton(null)) 阅读全文
posted @ 2020-06-16 11:31 八英里 阅读(2475) 评论(0) 推荐(0)
摘要:Map<String, BigDecimal> teacherContribution = resultList.stream().collect(Collectors.toMap(RankingTeacherTotal::getUserId, RankingTeacherTotal::getVal 阅读全文
posted @ 2020-06-16 11:23 八英里 阅读(344) 评论(0) 推荐(0)
摘要:工作中用到了list的取差集,发现还是挺好用的。所以记录下。 需求list的方法说明备注 交集 listA.retainAll(listB) listA内容变为listA和listB都存在的对象 listB不变 差集 listA.removeAll(listB) listA中存在的listB的内容去 阅读全文
posted @ 2020-06-16 10:25 八英里 阅读(3796) 评论(0) 推荐(0)
摘要:@Inject NamedParameterJdbcTemplate namedParameterJdbcTemplate; public List<TeacherContributionLastCalculated> searchLastCalculated(Set<String> fromIdL 阅读全文
posted @ 2020-06-03 14:38 八英里 阅读(1730) 评论(0) 推荐(0)
摘要:public int setIntPoint(double contribution, BigDecimal rate) { return BigDecimal.valueOf(contribution).multiply(rate).setScale(0, BigDecimal.ROUND_HAL 阅读全文
posted @ 2020-06-03 10:34 八英里 阅读(1912) 评论(0) 推荐(0)
摘要:debug启动的时候需要等半个小时甚至更长时间突然有一天发现debug启动不起来了, 在debug时,项目一直会出现 Connected to the VM ,address: 其实这不是debug报错,没有启动 其实是一直处于启动中状态,日志刷的很慢 原因,之前存在断点没有取消,造成启动缓慢 解决 阅读全文
posted @ 2020-05-29 19:41 八英里 阅读(930) 评论(0) 推荐(0)
摘要:public static void main(String[] args) { System.out.println("向上取整:" + (int) Math.ceil(96.1));// 97 (去掉小数凑整:不管小数是多少,都进一) System.out.println("向下取整" + (i 阅读全文
posted @ 2020-05-28 11:08 八英里 阅读(12506) 评论(0) 推荐(0)
摘要:Linux 运行jar包命令如下: 方式一 java -jar shareniu.jar 特点:当前ssh窗口被锁定,可按CTRL + C打断程序运行,或直接关闭窗口,程序退出 那如何让窗口不锁定? 方式二 java -jar shareniu.jar & &代表在后台运行。 特定:当前ssh窗口不 阅读全文
posted @ 2020-05-11 23:27 八英里 阅读(844) 评论(0) 推荐(0)
摘要:直接用java -jar xxx.jar,当退出或关闭shell时,程序就会停止掉。以下方法可让jar运行后一直在后台运行。 1. java -jar xxx.jar & 说明: 在末尾加入 & 符号 2. (1)执行java -jar xxx.jar后 (2)ctrl+z 退出到控制台,执行 bg 阅读全文
posted @ 2020-05-11 22:44 八英里 阅读(1801) 评论(0) 推荐(0)
摘要:1. ps -ef |grep java ps:将某个进程显示出来-A 显示所有程序。 -e 此参数的效果和指定"A"参数相同。-f 显示UID,PPIP,C与STIME栏位。 grep命令是查找中间的|是管道命令 是指ps命令与grep同时执行 这条命令的意思是显示有关redis有关的进程 2. 阅读全文
posted @ 2020-05-08 21:28 八英里 阅读(8751) 评论(0) 推荐(0)
摘要:今天公司技术支持的童鞋报告一个客户的服务不工作了,紧急求助,于是远程登陆上服务器排查问题。 查看采集数据的tomcat日志,习惯性的先翻到日志的最后去查看有没有异常的打印,果然发现了好几种异常信息,但是最多还是这个: 24-Nov-2016 09:54:21.116 SEVERE [http-nio 阅读全文
posted @ 2020-04-14 11:12 八英里 阅读(3836) 评论(0) 推荐(0)
摘要:List<String> tbList = Arrays.asList(result.getTb_name().split(",")); 阅读全文
posted @ 2020-04-03 17:06 八英里 阅读(925) 评论(0) 推荐(0)
摘要:private boolean tagsIsEqual(String curentFieldValue, String preFieldValue) { if (curentFieldValue == null || preFieldValue == null) return false; if ( 阅读全文
posted @ 2020-03-31 11:17 八英里 阅读(168) 评论(0) 推荐(0)
摘要:问题: No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK? 阅读全文
posted @ 2020-03-30 23:24 八英里 阅读(134) 评论(0) 推荐(0)
摘要:在该目录下 shift+ 右键 在此处打开powershell 阅读全文
posted @ 2020-03-30 21:48 八英里 阅读(495) 评论(0) 推荐(0)

上一页 1 ··· 6 7 8 9 10 11 下一页