|
|
|
@ -135,4 +135,18 @@ public class NewTest { |
|
|
|
String formatFileSize = SzFileUtils.fileSizeFormat(filesize); |
|
|
|
System.out.println("资源文件大小:"+formatFileSize); |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* 验证抽取时间 |
|
|
|
*/ |
|
|
|
@Test |
|
|
|
public void veryTimeTest(){ |
|
|
|
String rss="{\"isliCode\":\"010007-00000000278400000001-9\",\"message\":\"1\",\"revokeStatus\":\"2\",\"verifyStatus\":\"1\",\"timeStamp\":1665624047000,\"verifyTime\":1665624195000}"; |
|
|
|
JSONObject json = JSONObject.parseObject(rss); |
|
|
|
Long vstime = json.getLongValue("verifyTime"); |
|
|
|
//String vstime = json.getString("verifyTime");
|
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); |
|
|
|
String nowstr =sdf.format(vstime); |
|
|
|
System.out.println(nowstr); |
|
|
|
} |
|
|
|
} |
|
|
|
|