开发者

Java Date sorting method?

开发者 https://www.devze.com 2022-12-29 05:35 出处:网络
I have an String array of dates in the format ex:\'2010-05-04 11:26:46 +0530\'. How can I check whether a particular date in the array i开发者_如何学Gos > today?

I have an String array of dates in the format ex:'2010-05-04 11:26:46 +0530'. How can I check whether a particular date in the array i开发者_如何学Gos > today?

thanks


DateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss Z");

df.parse(datearray[i]).after(new Date()) 
0

精彩评论

暂无评论...
验证码 换一张
取 消