提交 031e5f4c authored 作者: 马晨俊's avatar 马晨俊

mcj:新增如果不上传源代码的逻辑

上级 f4b91a89
......@@ -144,11 +144,13 @@ public class Inspector {
public ReportVo inspect() throws IOException {
//初始化值
initData();
//扫描文件
scanFiles();
inspectParameter.setCodeSize((int) codeSize);
report.setFileNum(fileNum);
report.setFileLine(fileLine);
log.info("inspect:源代码扫描完成,统计各个文件后缀完成");
//统计项目语言
setReportLanguageAndFrame();
//根据扫描结果以及用户配置得出需要使用的规则及技术
ruleTransform(report.getRecastMethod());
......@@ -537,6 +539,7 @@ public class Inspector {
}
//文件读取
if(inspectParameter.getSourceAddress()!=null){
Files.walkFileTree(Paths.get(inspectParameter.getSourceAddress()), new FileVisitor<Path>() {
@Override
public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs) throws IOException {
......@@ -626,6 +629,7 @@ public class Inspector {
}
});
}
}
public class Counter {
private int i = 0;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论