It's all about the answers!

Ask a question

Java API : ChangeSummaryNode and ChangeSetNode


Gidi Gal (861529) | asked Apr 24 '19, 6:39 a.m.
edited Apr 24 '19, 10:35 a.m.
I am using Java API in order to retrieve information from the client about incoming change-sets. I am using com.ibm.team.filesystem.rcp.core.internal.changes.model.IComponentSyncModel to retrieve the information. The main purpose is to save on server hits and use the information stored in the client. I found the class ChangeSummaryNode which stores information for each file in the change-set. It has the two functions getBeforePath and getAfterPath which give the path to the file before and after the change. However, it is not a full path.I think it is missing the path to the component.

How do I build the path of the component, using the information in IComponentSyncModel ? (Or other services ?)
If the change was re-parented, how do I find the path of the source component ?

Thanks :-)

Comments
Luca Martinucci commented Apr 24 '19, 10:52 a.m.

Which kind of Java API are you using? The Plain Client API or the server-side SDK?

I have done several customizations involving change sets, and I have been able to build the full paths of the modified files, but using different Java classes than yours.


Gidi Gal commented Apr 24 '19, 11:05 a.m.
I am using Plain Client API. All my code is running in the client.
There is this service com.ibm.team.filesystem.client.internal.copyfileareas.ICopyFileAreaManager - I have code that uses this service and returns full path for workspace, component and versionable. So, I can use it to replace the full path before the change-set is accepted.
However, I was wondering whether there's a way to get the component\s path in order to append it to the paths in getBeforePath and getAfterPath.

Be the first one to answer this question!


Register or to post your answer.