循环修改

首页签出2023/07/24
宇宙皮皮娃 2 years ago
parent 7a150fd9ce
commit 3cdd4458f3

@ -33,7 +33,6 @@ public class HttpTBasicServiceImpl implements HttpTBasicService {
//解析返货值字符串
log.info("解析开始");
tBasicDtos=parsing(resultStr);
log.info("解析tBasicDtos"+tBasicDtos!=null? ((Integer) tBasicDtos.size()).toString() :"0"+"条");
}catch (Exception e){
log.error(e.getMessage(),e);
}

@ -87,7 +87,7 @@ public class TBasicServiceImpl implements ITBasicService {
modifyJsonFile(timeConfigFile,"startTime",beginTimeStr);
//分页查询
for(pageNum=1;true;i++){
for(;true;pageNum++){
//设置请求头信息
Map<String,String> headerMap =new HashMap<>();
headerMap.put("Content-Type","application/json");
@ -107,7 +107,6 @@ public class TBasicServiceImpl implements ITBasicService {
if(Func.isEmpty(tBasicDtoList)){
break;
}
//持久化对像集合转化
List<TBasic> tBasicList=new ArrayList<TBasic>();
for(TBasicDto tBasicDto:tBasicDtoList){
@ -208,6 +207,15 @@ public class TBasicServiceImpl implements ITBasicService {
}
public static void main(String[] args) {
int pageNum=1;
for(;true;pageNum++){
System.out.println(pageNum);
if(pageNum==10){
break;
}
}
}
public void modifyJsonFile(File file, String key, String value) {
StringBuilder sb = new StringBuilder();

Loading…
Cancel
Save