URLException
A URLException is a type of exception in Java that is thrown when an error related to a Uniform Resource Identifier (URI) or Uniform Resource Locator (URL) occurs. These exceptions are part of the java.net package and indicate problems that prevent a program from accessing or processing a web resource.
There are two main subclasses of URLException: MalformedURLException and UnknownHostException. A MalformedURLException is typically thrown when
An UnknownHostException, on the other hand, is a subclass of IOException, but it's often encountered in conjunction
When a URLException is thrown, it means that the Java runtime environment encountered an unrecoverable error