RTC Java API - add value to custom attribute of type 'WorkItem List'
Hi,
Using rtc plain java api. I am creating an automation tool where, I need to add a value to a custom attribute
of type 'Work Item list'.
Is it possible to save the attribute via
workItem.setValue(iAttribute, value);
or need to create a reference using
final ILink newLink = linkManager.createLink(WorkItemLinkTypes.RELATED_WORK_ITEM, workItemRef, relatedRef);
Or is there any other way.
Kindly suggest me how to do.
Best Regards,
One answer
See https://rsjazz.wordpress.com/2013/01/02/working-with-work-item-attributes/ section List Attributes.
That shows that you get a List<Object> where the Object is the type of the attribute. The same way you create a List variable and pass the list to setValue(). You can see various examples for this in the code available at https://rsjazz.wordpress.com/2017/03/29/the-work-item-command-line-is-now-open-source/ as well.