Code example for Gson

Methods: fromJson

0
	protected void configure() { 
	} 
 
	@Provides 
	public JambelConfiguration config() { 
		Gson gson = new Gson();
		try { 
			return gson.fromJson(new FileReader(new File(configFilePath)), JambelConfiguration.class);
		} catch (FileNotFoundException e) {
			throw new RuntimeException(e);
		} 
	} 
 
}