|
@@ -72,7 +72,8 @@ public class OBJToGLBUtil {
|
|
|
File objFile = null;
|
|
|
for (File file2 : files) {
|
|
|
if(file2.isDirectory()){
|
|
|
- return checkObj(file2.getPath());
|
|
|
+ //return checkObj(file2.getPath());
|
|
|
+ throw new BusinessException(ResultCode.UPLOAD_FILE_NO_EXIST);
|
|
|
}
|
|
|
if(file2.getName().contains(".obj") ){
|
|
|
objFile = file2;
|
|
@@ -92,7 +93,7 @@ public class OBJToGLBUtil {
|
|
|
throw new BusinessException(ResultCode.UPLOAD_FILE_OBJ_ERROR);
|
|
|
}
|
|
|
LinkedHashSet<String> imgName = new LinkedHashSet<>();
|
|
|
- if(allFile == null ){
|
|
|
+ if(allFile == null || allFile.length()<=0 ){
|
|
|
throw new BusinessException(ResultCode.UPLOAD_FILE_OBJ_ERROR);
|
|
|
}
|
|
|
File[] files = allFile.listFiles();
|
|
@@ -123,8 +124,6 @@ public class OBJToGLBUtil {
|
|
|
if(split1.length <=1){
|
|
|
continue;
|
|
|
}
|
|
|
- System.out.println(split1[1]);
|
|
|
- System.out.println(isNumeric2(split1[1]));
|
|
|
if(isNumeric2(split1[1])){
|
|
|
String[] split2 = split1[1].split("\\.");
|
|
|
int number = Integer.parseInt(split2[0]);
|