After you've successfully created a URL , you can call the URL 's openStream() method to get a stream from which you can read the contents of the URL.
docs.oracle.com