calendar - dividing time using Java -
i doing yahoo product api getting products yahoo using time limit. pass start time , end time products available between date. passing dates url provide getting products.
in yahoo there limitation 1000 products per phone call doing give 1 month time limit , create phone call , products in time limit. cases wont exceed 1000 in case if exceed 1000 products want split time half (1 month 15 day time gap) , check 1 time again , repeat until less 1000 products in time stamp.
i have done other things except dividing time. please help me that.
use joda-time library:
seconds diff = seconds.secondsbetween(start,end); int halfdiff = diff.getseconds()/2; end = end.minusseconds(halfdiff) java calendar jodatime java-time
No comments:
Post a Comment