List of usage examples for org.json XMLToJson XMLToJson
public XMLToJson(String basePath)
From source file:mayo.edu.server.JsonServiceImpl.java
@Override public String getJsonFromXml(String xml) throws IllegalArgumentException { return new XMLToJson(getBasePath()).toJson(xml); }
From source file:mayo.edu.server.JsonServiceImpl.java
@Override public XmlJsonResponse getJsonFromRestService(String restUrl) throws IllegalArgumentException { String xml = makeRestCall(restUrl); String json = new XMLToJson(getBasePath()).toJson(xml); XmlJsonResponse response = new XmlJsonResponse(); response.setJson(json);// w ww. j a va2 s.co m response.setXml(xml); return response; }