这篇文章主要介绍了SpringBoot如何使用Fastjson解析Json数据,文中通过示例代码介绍的非常详细,对大家的学习或者工作具有一定的参考学习价值,需要的朋友可以参考下
方法一:
1.在pom.xml文件下添加依赖包
com.alibaba fastjson 1.2.15
2.修来源gaodaimacom搞#^代%!码网改启动文件
package myshop; import java.util.List; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.http.converter.HttpMessageConverter; import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter; import com.alibaba.fastjson.serializer.SerializerFeature; import com.alibaba.fastjson.support.config.FastJsonConfig; import com.alibaba.fastjson.support.spring.FastJsonHttpMessageConverter; @SpringBootApplication public class App extends WebMvcConfigurerAdapter{ @Override public void configureMessageConverters(List
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持gaodaima搞代码网。
以上就是SpringBoot如何使用Fastjson解析Json数据的详细内容,更多请关注gaodaima搞代码网其它相关文章!