Fully mirgate main source to Java NIO (except some files in tools).
This commit is contained in:
@@ -24,7 +24,6 @@ package provider;
|
||||
import provider.wz.WZFiles;
|
||||
import provider.wz.XMLWZFile;
|
||||
|
||||
import java.io.File;
|
||||
import java.nio.file.Path;
|
||||
|
||||
public class DataProviderFactory {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package provider.wz;
|
||||
|
||||
import java.io.File;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
import java.nio.file.Paths;
|
||||
|
||||
@@ -38,7 +38,7 @@ public enum WZFiles {
|
||||
private static String getWzDirectory() {
|
||||
// Either provide a custom directory path through the "wz-path" property when launching the .jar, or don't provide one to use the default "wz" directory
|
||||
String propertyPath = System.getProperty("wz-path");
|
||||
if (propertyPath != null && new File(propertyPath).isDirectory()) {
|
||||
if (propertyPath != null && Files.isDirectory(Paths.get(propertyPath))) {
|
||||
return propertyPath;
|
||||
}
|
||||
|
||||
|
||||
@@ -34,7 +34,6 @@ import javax.xml.parsers.DocumentBuilder;
|
||||
import javax.xml.parsers.DocumentBuilderFactory;
|
||||
import javax.xml.parsers.ParserConfigurationException;
|
||||
import java.awt.*;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
import java.nio.file.Path;
|
||||
|
||||
Reference in New Issue
Block a user