private JSONObject getJSONFromPath ( String path ) throws LRException { JSONObject json = null ; String jsonTxt = null ; try { jsonTxt = LRClient . executeJsonGet ( importProtocol + "://" + nodeHost + path ) ; } catch ( Exception e ) { throw new LRException ( LRException . IMPORT_FAILED ) ; //e.printStackTrace(); } try { json = new JSONObject ( jsonTxt ) ; } catch ( JSONException e ) { throw new LRException ( LRException . JSON_IMPORT_FAILED ) ; //e.printStackTrace(); } return json ; }
Get the data from the specified path as a JSONObject