Hi,
I am using the DAMUtil API and calling the findExpiringAssets function but it is returning nothing. I am storing the result in a list and the size of this list is 0. best guess is that it is not able to compare the 2 dates (lower bound and upper bound). as there is no exception log.
Is there a specific format in which these dates needs to be for a proper comparison? I have checked the value of the property (prism:expirationDate). it is in format 2015-07-01T11:00:00.000+05:30.
This is ISO8601 standard timeformat. We can format a date in this format using the methods provided in class ISO8601 in org.apache.jackrabbit.util package. but still I am not getting any result.
-List <String> expiringAssets = DamUtil.findExpiringAssets(sess, lb, ub);
--Calendar lb = DateToCalendarLB();
Calendar ub = DateToCalendarUB();
The method DateToCalendarLB():
Calendar cal=Calendar.getInstance();
cal.setTime(new Date());
String dateString = ISO8601.format(cal);
Calendar cal1 = ISO8601.parse(dateString);
return cal1;
Still not getting any result on this. ANy pointer would be helpful.
Thanks