Have a test program
public class Path {
public static void main(String[] args) {
System.out.println("user.dir=" + System.getProperty("user.dir"));
System.out.println(Path.class.getResource(Path.class.getSimpleName() + ".class").toString());
}
}
The output:
user.dir=/home/stas/ява
file:/home/stas/%d1%8f%d0%b2%d0%b0/Path.class
How can i read the path to file using the second way correctly?
try