When composing a File from a path and a name, the constructor
should check if the path already ends in a separator, to avoid getting
double separators between path and name.
public File(String path, String name) {
this((path != null) ? path + separator + name : name);
}
should check if the path already ends in a separator, to avoid getting
double separators between path and name.
public File(String path, String name) {
this((path != null) ? path + separator + name : name);
}