随笔分类 -  JAVA

上一页 1 2 3 4 5 6 7 8 9 10 ··· 19 下一页
JAVA一些常用的方法
摘要:官方出了文档:http://doc.ruoyi.vip/ruoyi/document/cjjc.html#%E9%9B%86%E6%88%90mybatis-plus%E5%AE%9E%E7%8E%B0mybatis%E5%A2%9E%E5%BC%BA RuoYi框架默认使用的是Mybatis框架 阅读全文
posted @ 2021-10-05 12:36 yvioo 阅读(4074) 评论(0) 推荐(0)
摘要:聚合函数查询 Mysql可以使用以下方法 QueryWrapper queryWrapper = new QueryWrapper<>(); queryWrapper.select(" IFNULL( max(percent),0) as maxPercent"); Map<String, Inte 阅读全文
posted @ 2021-10-04 20:41 yvioo 阅读(23615) 评论(0) 推荐(2)
摘要:把$velocityCount替换成$foreach.count 例如 #if($foreach.count != $columns.size()),#end 阅读全文
posted @ 2021-10-03 15:44 yvioo 阅读(669) 评论(0) 推荐(0)
摘要:或者 pom增加插件 <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <version>2.5</version> <configuration> 阅读全文
posted @ 2021-09-29 11:01 yvioo 阅读(313) 评论(0) 推荐(0)
摘要:pom依赖 <dependency> <groupId>org.java-websocket</groupId> <artifactId>Java-WebSocket</artifactId> <version>1.3.8</version> </dependency> <dependency> < 阅读全文
posted @ 2021-09-27 14:19 yvioo 阅读(9900) 评论(1) 推荐(0)
摘要:pom依赖 <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-actuator</artifactId> </dependency> 配置文件yml management. 阅读全文
posted @ 2021-09-26 14:06 yvioo 阅读(1139) 评论(0) 推荐(0)
摘要:判断字符串为空和判断集合是否为空用到依赖,也可以改成自己的方式 <!-- Spring Web --> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-web</artifactId> <version>5 阅读全文
posted @ 2021-09-24 15:46 yvioo 阅读(2511) 评论(0) 推荐(0)
摘要:引入依赖 <dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-starter-gateway</artifactId> </dependency> 我和nacos整合了 引入了下面的依赖 阅读全文
posted @ 2021-09-22 14:41 yvioo 阅读(5537) 评论(0) 推荐(0)
摘要:上面这个调试端口并不是服务的启动端口,这个调试端口随便给一个,可以直接IDEA默认,只要不是远程服务启动端口就行 然后将上面的执行参数复制下来 -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=8086 放到服务器上 在执行j 阅读全文
posted @ 2021-09-13 13:35 yvioo 阅读(1321) 评论(0) 推荐(0)
摘要:for (Map.Entry<String, String> entry : map.entrySet()) { System.out.println("key= " + entry.getKey() + " and value= " + entry.getValue()); } for (Stri 阅读全文
posted @ 2021-09-03 08:58 yvioo 阅读(46) 评论(0) 推荐(0)
摘要:public static void main(String[] args) throws InterruptedException { CountDownLatch latch =new CountDownLatch(10); for (int i = 0; i < 900; i++) { new 阅读全文
posted @ 2021-09-02 10:17 yvioo 阅读(70) 评论(0) 推荐(0)
摘要:User[] users= restTemplate.getForObject(url, User[].class); 使用数组接收 阅读全文
posted @ 2021-08-20 15:06 yvioo 阅读(968) 评论(0) 推荐(0)
摘要:import java.io.IOException; import java.lang.reflect.Field; import java.util.HashMap; import java.util.Map; /*** * 通过java Class 生成查询语句 */ public class 阅读全文
posted @ 2021-08-12 16:08 yvioo 阅读(681) 评论(0) 推荐(0)
摘要:个人习惯使用 实现的方式 public class WebMvcConfiguration implements WebMvcConfigurer { 阅读全文
posted @ 2021-08-11 11:02 yvioo 阅读(413) 评论(0) 推荐(0)
摘要:依赖 <!-- springboot整合websocket --> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-websocket</artifactId> </de 阅读全文
posted @ 2021-07-28 14:16 yvioo 阅读(200) 评论(0) 推荐(0)
摘要:SpringUtils.java import org.springframework.beans.BeansException; import org.springframework.beans.factory.config.BeanFactoryPostProcessor; import org 阅读全文
posted @ 2021-07-27 14:36 yvioo 阅读(958) 评论(0) 推荐(0)
摘要:private static final SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd"); public static List<String> splitDateList(Date startDate, Date e 阅读全文
posted @ 2021-07-26 17:39 yvioo 阅读(3340) 评论(0) 推荐(0)
摘要:import org.apache.commons.io.IOUtils; byte[] bytes = IOUtils.toByteArray(inputStream); 如果没有这个包 就加下依赖 <!-- https://mvnrepository.com/artifact/commons-i 阅读全文
posted @ 2021-07-22 14:28 yvioo 阅读(4153) 评论(0) 推荐(0)
摘要:官方文档:https://www.xuxueli.com/xxl-job/#%E3%80%8A%E5%88%86%E5%B8%83%E5%BC%8F%E4%BB%BB%E5%8A%A1%E8%B0%83%E5%BA%A6%E5%B9%B3%E5%8F%B0XXL-JOB%E3%80%8B 官方代码: 阅读全文
posted @ 2021-07-21 13:15 yvioo 阅读(504) 评论(0) 推荐(0)
摘要:bootstrap.yml需要引入springcloud的包才会加载 第一种: <dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-starter-bootstrap</artifact 阅读全文
posted @ 2021-07-20 17:59 yvioo 阅读(3518) 评论(0) 推荐(0)

上一页 1 2 3 4 5 6 7 8 9 10 ··· 19 下一页