protected void processCommand(JSONModel jsonModel){
		String type = "";
		try {
			type = jsonModel.getString("_type");
		} catch (JSONException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		L.i("type", type);
		if (type.equals("launch_url")) {
			try {
				JSONObject obj = jsonModel.jsonObject;
				
				JSONObject argsObj = obj.getJSONObject("args");
				String url = argsObj.getString("url");
				launchUrl(url);
				
			} catch (JSONException e) {
				// TODO Auto-generated catch block
				e.printStackTrace();
			}
			waitForRequest();
		}
		else if (type.equals("download_files")) {
			try {
				JSONObject obj = jsonModel.jsonObject;
				
				JSONObject argsObj = obj.getJSONObject("args");
				JSONArray filesArr = argsObj.getJSONArray("files");
				
				for (int i = 0; i < filesArr.length(); ++i) {
					JSONObject fileObj = filesArr.getJSONObject(i);
					String url = fileObj.getString("url");
					String targetDir = fileObj.getString("targetdir");
					downloadFile(url, targetDir);
				}
				
			} catch (JSONException e) {
				// TODO Auto-generated catch block
				e.printStackTrace();
			}
		}
		else if (type.equals("upload_files")) {
			try {
				JSONObject obj = jsonModel.jsonObject;
				JSONObject cookieObj = obj.getJSONObject("request_cookie");
				JSONObject argsObj = obj.getJSONObject("args");
				JSONArray filesArr = argsObj.getJSONArray("files");
				
				
				for (int i = 0; i < filesArr.length(); ++i) {
					String fname = filesArr.getString(i);
					uploadFile(fname, url);
				}
				
			} catch (JSONException e) {
				// TODO Auto-generated catch block
				e.printStackTrace();
			}
		}
		
	}