Code example for JSONException

Methods: printStackTrace

0
            + "' was not successful: " + result);
      } 
 
      return result;
    } catch (JSONException e) {
      e.printStackTrace();
      throw new CalabashException("Error ocured while parsing calabash-driver response.", e);
    } 
  } 
 
  protected Object get(WebDriverLikeCommand command, JSONObject payload) {
    Path p = new Path(command).withSession(getSessionId());
 
    WebDriverLikeRequest request = new WebDriverLikeRequest(command.method(), p, payload);
    WebDriverLikeResponse response = execute(request);
    if (response == null || response.getValue() == JSONObject.NULL) {
      return null; 
    } else { 
      return response.getValue();
    } 
  }