mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-28 15:20:54 +07:00
20 lines
557 B
Java
20 lines
557 B
Java
// "Fix all 'Redundant 'File' instance creation' problems in file" "true"
|
|
import java.io.*;
|
|
import java.util.Formatter;
|
|
|
|
class Main {
|
|
private static String getSomePathname() {
|
|
return "Some pathname";
|
|
}
|
|
|
|
public void main(String[] args) throws IOException {
|
|
new FileInputStream(getSomePathname());
|
|
new FileOutputStream(getSomePathname());
|
|
new FileReader(getSomePathname());
|
|
new FileWriter(getSomePathname());
|
|
new PrintStream(getSomePathname());
|
|
new PrintWriter(getSomePathname());
|
|
new Formatter(getSomePathname());
|
|
}
|
|
}
|