invXMLStr = null; try {   BufferedReader p = new BufferedReader(new InputStreamReader(is,Charset.forName("ASCII"))); invXMLStr = p.readLine() + "\n"; String currLine = p.readLine(); while(currLine != null) { invXMLStr =  invXMLStr + currLine + "\n"; currLine = p.readLine();
invXMLStr = null; try {   BufferedReader p = new BufferedReader(new InputStreamReader(is, Charset.forName("ASCII"))); invXMLStr = p.readLine() + "\n"; String currLine = p.readLine(); while (currLine != null) { invXMLStr = invXMLStr + currLine + "\n"; currLine = p.readLine(); } p.close(); connection.closeConnection(); } catch (Exception e) { displayErrorString("getInventoryData:Object read exception: " + e);
  public String getInventoryData(String orgName, String assetName) {InputStream is = null;ConnectionHelper connection=null;String orgURL = (String)orgURLs.get(orgName); if(logger.isInfoEnabled()) {logger.info("ExecutingQuery: " + assetName + " to: " + orgURL +                     " for: " + SERV_ID); }try {    connection =  new ConnectionHelper( orgURL, SERV_ID);    connection.sendData(assetName);    is = connection.getInputStream();} catch (Exception e) {    displayErrorString(e.toString());}invXMLStr = null;try {    //ObjectInputStream p = new ObjectInputStream(is);    //invXMLStr = (String)p.readObject();    BufferedReader p = new BufferedReader(new InputStreamReader(is,Charset.forName("ASCII")));    invXMLStr = p.readLine() + "\n";    String currLine = p.readLine();    while(currLine != null) {	invXMLStr =  invXMLStr + currLine + "\n";	currLine = p.readLine();    }    p.close();    connection.closeConnection();} catch (Exception e) {    displayErrorString("getInventoryData:Object read exception: " + e);}	//parse here	return invXMLStr;    }