Since split needs regex, added function that returns regex according to systems file separator.
This commit is contained in:
@@ -339,4 +339,12 @@ public class FileReaderWriter {
|
||||
return content;
|
||||
}
|
||||
}
|
||||
|
||||
public static String getFileSeparatorRegex() {
|
||||
if (File.separator.equals("\\")) {
|
||||
return "\\\\";
|
||||
} else {
|
||||
return File.separator;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user