Rekha
Rekha

Reputation: 11

How to find whether a RTC workitem is already created

I am able to create work item in RTC through java application using the jazz api's with Custom attribute with Patch Id.

Now I have to find whether any workitem is created with that patch id. If a workitem is already present, it should not get duplicated.

Tried the below code,

List<Integer> patch_list=new ArrayList();

patch_list.add(patch_id);

List<IWorkItemHandle> workItemHandle = workItemClient.findWorkItemsById(patch_list, new SysoutProgressMonitor());

for(int j = 0; j < workItemHandle.size(); j++){

    System.out.println(workItemHandle.get(j));
}

But it is returning null value instead of 193.

Can anyone suggest me on this.

Thank you in advance.

Upvotes: 1

Views: 88

Answers (0)

Related Questions