code: public static String streamToString(InputStream is, String charsetName) {
  		try {
  			Reader r = null;
  			try {
  				r = new BufferedReader(new InputStreamReader(is, charsetName));
  				return readerToString(r);
  			} finally {
  				if (r != null) {
  					try {
  						r.close();
  					} catch (IOException e) {
  					}
  				}
  			}
  		} catch (Exception e) {
  			throw new RuntimeException(e);
  		}
  
  	}
docs: Transforms a stream into a string.
  
  @param is
  the stream to be transformed
  @param charsetName
  encoding of the file
  @return the string containing the content of the stream