public static String toString(URL url,Charset encoding) throws IOException {
  InputStream inputStream=url.openStream();
  try {
    return toString(inputStream,encoding);
  }
  finally {
    inputStream.close();
  }
}

public static String toString ( URL url , Charset encoding ) throws IOException { InputStream inputStream = url . openStream ( ) ; try { return toString ( inputStream , encoding ) ; } finally { inputStream . close ( ) ; } }
gets the contents at the given url .
