Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package com.leviathanstudio.wolf.json;
- import java.io.InputStream;
- import java.io.InputStreamReader;
- import com.google.gson.JsonObject;
- import com.google.gson.JsonParser;
- public class JsonConfiguration
- {
- private static JsonObject configObj;
- public void init()
- {
- JsonParser parser = new JsonParser();
- InputStream in = this.getClass().getResourceAsStream("/config/config.json");
- configObj = parser.parse(new InputStreamReader(in)).getAsJsonObject();
- System.out.println("Config file path : " + configObj);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement