mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 07:14:30 +02:00
8194746: (fs) Add equivalents of Paths.get to Path interface
Copy Paths.get() methods to Path.get() methods and have former call latter Reviewed-by: alanb, forax, chegar, psandoz
This commit is contained in:
parent
37f1b2b1e3
commit
9e3d8fd230
18 changed files with 174 additions and 119 deletions
|
@ -30,7 +30,7 @@ import java.lang.reflect.*;
|
|||
import java.net.MalformedURLException;
|
||||
import java.net.URL;
|
||||
import java.net.URI;
|
||||
import java.nio.file.Paths;
|
||||
import java.nio.file.Path;
|
||||
import java.util.*;
|
||||
import java.security.*;
|
||||
import java.security.cert.Certificate;
|
||||
|
@ -278,7 +278,7 @@ public class PolicyFile extends java.security.Policy {
|
|||
public URL run() {
|
||||
String sep = File.separator;
|
||||
try {
|
||||
return Paths.get(System.getProperty("java.home"),
|
||||
return Path.of(System.getProperty("java.home"),
|
||||
"lib", "security",
|
||||
"default.policy").toUri().toURL();
|
||||
} catch (MalformedURLException mue) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue