removed custom URLStreamHandlerFactory
This commit is contained in:
@@ -43,9 +43,6 @@ public class Launcher {
|
|||||||
|
|
||||||
@SneakyThrows
|
@SneakyThrows
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) {
|
||||||
URLManager urlManager = URLManager.getInstance();
|
|
||||||
urlManager.registerProtocol(PathURLStreamHandler.SCHEME, PathURLStreamHandler.INSTANCE);
|
|
||||||
URL.setURLStreamHandlerFactory(urlManager);
|
|
||||||
Enumeration<URL> it = Launcher.class.getClassLoader().getResources(Constants.SYSTEM_PROPERTIES_FILE);
|
Enumeration<URL> it = Launcher.class.getClassLoader().getResources(Constants.SYSTEM_PROPERTIES_FILE);
|
||||||
while (it.hasMoreElements()) {
|
while (it.hasMoreElements()) {
|
||||||
URL url = it.nextElement();
|
URL url = it.nextElement();
|
||||||
|
@@ -1,7 +1,10 @@
|
|||||||
package envelope.test.jpms;
|
package envelope.test.jpms;
|
||||||
|
|
||||||
|
import java.net.MalformedURLException;
|
||||||
|
import java.net.URL;
|
||||||
public class Main {
|
public class Main {
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) throws MalformedURLException {
|
||||||
|
new URL("https://www.google.com");
|
||||||
System.out.println("Hello World!!");
|
System.out.println("Hello World!!");
|
||||||
}
|
}
|
||||||
}
|
}
|
@@ -1,7 +1,10 @@
|
|||||||
package envelope.test.legacy;
|
package envelope.test.legacy;
|
||||||
|
|
||||||
|
import java.net.MalformedURLException;
|
||||||
|
import java.net.URL;
|
||||||
public class Main {
|
public class Main {
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) throws MalformedURLException {
|
||||||
|
new URL("https://www.google.com");
|
||||||
System.out.println("Hello World!!");
|
System.out.println("Hello World!!");
|
||||||
}
|
}
|
||||||
}
|
}
|
Reference in New Issue
Block a user