Using handles as map keys
https://jazz.net/wiki/bin/view/Main/RTCSDK20_SourceControl warns against using item handles as map keys.
The javadoc for com.ibm.team.scm.common.dto.IChangeHistorySyncReport.localBases() says that IComponentHandle is used as the key for the returned map. Is it safe to use handles for map keys? Is it only safe for certain kinds of handles? |
2 answers
|
Ralph Schoon (63.5k●3●36●46)
| answered Apr 04 '11, 5:14 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
Hi,
I searched for references for Work Item handles in the SDK. package com.ibm.team.apt.internal.client.private DTO_ResolvedWorkItem2 checkForParentCycles(List<DTO_ResolvedWorkItem2> items) Uses handles as map keys. I would assume it is safe then. Otherwise you could use the ID. Ralph Still waiting for an answer on this one. |
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.