It's all about the answers!

Ask a question

Basic scm operations with the Java API


0
1
Oscar Picasso (311420) | asked Jan 28 '14, 3:17 p.m.
retagged Jan 31 '14, 4:15 p.m. by Dejan Custic (2855)
 Is there some documentation / javadoc on how to perform the following commands with the RTC Java API:
- load (simple load of a repository workspace, no rules)
- accept
- deliver

These commands will not be called interactively from an IDE but from a maven plugin called on the command line (the plugin is written in java).

We use RTC version 4.0.3.

Comments
sam detweiler commented Jan 28 '14, 4:35 p.m. | edited Jan 28 '14, 4:36 p.m.

see the Javadoc supplied in the download area for each RTC release


see the SCMPlatform and IWorkspace objects


Shashikant Padur commented Jan 28 '14, 10:09 p.m. | edited Jan 28 '14, 10:09 p.m.
JAZZ DEVELOPER

 Why not use the scm commandline? The scm cli can output the result in json format that could be easily parsed by any program.


Oscar Picasso commented Jan 29 '14, 10:02 a.m.

@sam


I read the Javadoc supplied  in the release area, and especially the SCMPlatform and IWorkspace objects.

I found the information about many other commands I like to use (create workspace, build definitions etc.) but not for the three basic mentioned in my post. Could you give some example for these commands?

@Shashikant
I already use the Java API extensively to create many objects, some that cannot be created from the command line like build definition. To be consistent I would like to continue to use the Java API.

Futhermore I need to call the commands from Java so it make sens to use the Java API.

Accepted answer


permanent link
Tim Mok (6.6k38) | answered Jan 29 '14, 2:10 p.m.
JAZZ DEVELOPER
The plain Java client download comes with snippets that may help. Snippet2.java shows how to deliver changes. Accepting is similar except you call IWorkspaceConnection#accept(...) Loading is more complicated and the documentation for this isn't published because it isn't considered supported API for public use. I would recommend what Shashikant suggests and use the CLI.
Oscar Picasso selected this answer as the correct answer

One other answer



permanent link
Dejan Custic (2855) | answered Jan 31 '14, 4:15 p.m.
FORUM MODERATOR / JAZZ DEVELOPER
edited Jan 31 '14, 5:03 p.m.
For reference, the SCM CLI Help is here http://pic.dhe.ibm.com/infocenter/clmhelp/v4r0m3/topic/com.ibm.team.scm.doc/topics/r_scm_cli_scm.html

There are also example topics for load, accept, and deliver.

Your answer


Register or to post 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.