IDEA-228553 - added intention action to wrap string literal by Path.of

GitOrigin-RevId: a3c3b43e9421375c6cd4e8d1980d7a13ea392167
This commit is contained in:
Ilyas Selimov
2020-05-28 11:34:55 +07:00
committed by intellij-monorepo-bot
parent dced5078cb
commit 286820138e
6 changed files with 78 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
// "Wrap parameter using 'Paths.get()'" "true"
import java.nio.file.*;
class Test {
void m() {
Files.readString(Paths.get("path"));
}
}

View File

@@ -0,0 +1,10 @@
// "Wrap parameter using 'Path.of()'" "true"
import java.nio.file.*;
class Test {
void m() {
Files.readString(Path.of("path"));
}
}

View File

@@ -0,0 +1,10 @@
// "Wrap parameter using 'Paths.get()'" "true"
import java.nio.file.*;
class Test {
void m() {
Files.readString("<caret>path");
}
}

View File

@@ -0,0 +1,10 @@
// "Wrap parameter using 'Path.of()'" "true"
import java.nio.file.*;
class Test {
void m() {
Files.readString("<caret>path");
}
}