![](https://img-blog.csdnimg.cn/20201014180756757.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
工具类
E_N_D123
这个作者很懒,什么都没留下…
展开
-
fastjson工具的使用
添加pom.xml依赖<dependency> <groupId>com.alibaba</groupId> <artifactId>fastjson</artifactId> <version>1.2.47</version> </dependency>测试类测试@Test public void test3.原创 2021-01-05 17:06:45 · 134 阅读 · 0 评论 -
Lombox的使用(maven)
在idea中下载Lombox的插件!](https://img-blog.csdnimg.cn/20210105094006393.png?x-oss-process=image/watermark,type_ZmFuZ3poZW5naGVpdGk,shadow_10,text_aHR0cHM6Ly9ibG9nLmNzZG4ubmV0L3dlaXhpbl80NzI0OTg2OQ==,size_16,color_FFFFFF,t_70)在pom.xml文件中添加Lombox的依赖<depend.原创 2021-01-05 09:46:14 · 137 阅读 · 0 评论 -
自定义日期格式
使用util包下的Date创建的对象为一个Timestamp(时间戳)Date date = new Date();要想自定义日期格式,可以创建SimpleDateFormat对象,通过使用该对象的format()方法来自定义日期格式.Date date = new Date();SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");String format = sdf.format(date);..原创 2021-01-04 20:23:21 · 643 阅读 · 0 评论 -
利用Jackson解决Json乱码问题
导入Jackson依赖:<dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-databind</artifactId> <version>2.10.0</version> </dependency>在sprin.原创 2021-01-04 19:51:26 · 887 阅读 · 0 评论 -
使用spring的过滤器
直接在web.xml中配置: <filter> <filter-name>encoding</filter-name> <filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class> <init-param> <param-name>encod原创 2021-01-04 17:44:22 · 47 阅读 · 0 评论 -
完整的filter过滤器的编写
编写Filter实现类package com.kuang.filter;import javax.servlet.*;import java.io.IOException;/** * @ClassName EncondingFilter * @Author yin cun yu * @date 2021.01.04 17:19 */public class EncondingFilter implements Filter { public void init(Filte.原创 2021-01-04 17:36:01 · 288 阅读 · 0 评论