how to make changeset suspend, resume or disacard using RTC client api
![]()
Hi All,
How do I change state of changeset using RTC client using jazz client java api. I need to change state(discard, resume, suspend) using java client api. I have tried below code of snippet, but this is not working public boolean discardChangeSet(IWorkspaceConnection workspace, List<IChangeSetHandle> changeSetsHandle) throws TeamRepositoryException { workspace.discardChangeSets(true, changeSetsHandle, null); } public boolean suspendChangeSet(ITeamRepository repo,IWorkspaceHandle workspaceHandle, IWorkspaceConnection workspace, List<IChangeSetHandle> changeSetsHandles) throws TeamRepositoryException { IScmService scmService = (IScmService) repo.getClientLibrary(IScmService.class); IChangeSetHandle[] changeSets = Arrays.copyOf( changeSetsHandles.toArray(), changeSetsHandles.toArray().length, IChangeSetHandle[].class); scmService.suspend( workspaceHandle, changeSets, IScmService.DELTA_PER_INVOCATION , null, null); //workspace.suspend(changeSetsHandles, null); } After trying for scmService.suspend method it throws null pointer exception. public boolean resumeChangeSet(IWorkspaceConnection workspace, List<IChangeSetHandle> changeSetsHandles) throws TeamRepositoryException { workspace.resume(1, changeSetsHandles, null); } Could you please let me how to proceed on this. Sample code would be very much helpful. Thank you in advance |
One answer
![]()
Ralph Schoon (63.3k●3●36●46)
| answered Jan 05 '17, 3:16 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
|
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.