课程: Java 8+ Essential Training: Objects and APIs

今天就学习课程吧!

今天就开通帐号,24,600 门业界名师课程任您挑!

Parse a JSON file

Parse a JSON file

- [Instructor] There are many tasks that Java doesn't provide tools for. For example, if you want to parse files that are in the JSON data format, you won't find anything in the library that does it for you. That's a feature that was intended to be part of a number of versions of Java but it's just never been released as part of the core product. So instead, you tend to go looking for open source libraries that do the work you need to do. There are many of these in the Java world and for JSON, one of these tools is called Gson. You'll find it here on GitHub. It's an open source library and it's completely free. It was created by Google, but anybody can download this code and use it in their applications. There are many different ways to use a Java library and each library is responsible for giving you the instructions. There are tools for incorporating libraries through something called dependencies, but that goes beyond what we're working on in this course, which is the core…

内容