|
|
@ -65,7 +65,7 @@ public class C9 {
|
|
|
|
System.out.println("文件名无法解析为城市:" + fileName);
|
|
|
|
System.out.println("文件名无法解析为城市:" + fileName);
|
|
|
|
System.exit(0);
|
|
|
|
System.exit(0);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
System.out.println("正在处理" + cityName + "市州文件...");
|
|
|
|
System.out.println("正在处理" + cityName + "...");
|
|
|
|
//数据在图表1
|
|
|
|
//数据在图表1
|
|
|
|
int chartNumber = 1;
|
|
|
|
int chartNumber = 1;
|
|
|
|
//chartNumber:第几个图表
|
|
|
|
//chartNumber:第几个图表
|
|
|
@ -73,8 +73,10 @@ public class C9 {
|
|
|
|
//expectLimit:期望的数据行数,首先用POI进行解析,如果获取的行数大于预期行数,就是正确的,否则就需要二次调用python进行读取
|
|
|
|
//expectLimit:期望的数据行数,首先用POI进行解析,如果获取的行数大于预期行数,就是正确的,否则就需要二次调用python进行读取
|
|
|
|
List<List<String>> source = ExcelKit.getChartData(file.getAbsolutePath(), chartNumber - 1, 6);
|
|
|
|
List<List<String>> source = ExcelKit.getChartData(file.getAbsolutePath(), chartNumber - 1, 6);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
System.out.println("当前城市数据条目数量=" + source.size());
|
|
|
|
//遍历source
|
|
|
|
//遍历source
|
|
|
|
for (List<String> r : source) {
|
|
|
|
for (List<String> r : source) {
|
|
|
|
|
|
|
|
|
|
|
|
Row outRow = outSheet.createRow(++rowIndex);
|
|
|
|
Row outRow = outSheet.createRow(++rowIndex);
|
|
|
|
// 导出数据
|
|
|
|
// 导出数据
|
|
|
|
//上级行政区划,行政区划,年份,总人口变化,总人口预测
|
|
|
|
//上级行政区划,行政区划,年份,总人口变化,总人口预测
|
|
|
|