Code example for JsonReader

Methods: nextName

public class ConfigurationHelper { 
	private static void validateJsonName(JsonReader reader, String name)
			throws IOException { 
		if (!reader.nextName().equals(name))
			throw new IOException("Illegal JSON format!");
	public static Configuration readFromJsonFile(File file) throws IOException {
		return readFromJsonFile(file, null);
	public static Configuration readFromJsonFile(File file,
			EncryptionCallback encryptionCallback) throws IOException {
		FileReader fileReader = new FileReader(file);
		JsonReader reader = new JsonReader(fileReader);
		Configuration configuration;
		Encryption encryption;
Connect your IDE to all the code out there  Get Codota for Java