Code example for Gson

Methods: fromJson

0
		} 
		 
	} 
	 
	private void parseConfirm(String json) {
		Gson gson = new Gson();
		StringResponse response = gson.fromJson(json,  StringResponse.class);
		 
		if (response != null) {
			Toast.makeText(getApplicationContext(), response.getMessage(), Toast.LENGTH_SHORT).show();
			loadData(); 
		} 
	} 
 
	private void parseRequests(String result) {
		Gson gson = new Gson();
		UserListResponse response = gson.fromJson(result, UserListResponse.class);
		 
		if (response != null) {
			List<User> user_list = response.getObject();