javadate-rangesailpoint

How do we set daterange in Sailpoint IIQ


I'm trying to set the daterange of a report dynamically. But it seems as if the package I'm using doesn't implement the interface Serializable as it is supposed to. Do you have any idea how I can handle a date range with Sailpoint? There is my package: org.jfree.data.time.DateRange

I don't get any error when I set a string object, while I'm having this with dateRange:

java.lang.Exception: sailpoint.tools.GeneralException:
  The application script threw an exception:
    sailpoint.tools.xml.ConfigurationException:
      No serializer registered for class class org.jfree.data.time.DateRange

It happened when I do context.commitTransaction(), after saving the object.

Thank you


Solution

  • I found the solution. Daterange is not the type of the object, it's just a precision on the interface. If you have a date range to set, do so :

     TaskDefinition task = context.getObjectByName(TaskDefinition.class, "The name of the report");
      Map map = new HashMap();
      map.put("end",end_date_convert_in_long); 
      map.put("start",start_date_convert_in_long); 
      task.setArgument("the name of the variable", map); 
      context.saveObject(task);
      context.commitTransaction();