It's all about the answers!

Ask a question

Delete Category in a Category Schema using RAM Java API


Sanjay Karnam (4144) | asked Apr 24 '12, 1:24 p.m.
We have a need to delete categories in a category schema using the RAM Java API. Here's what we are doing...

RAMCategory categoryToDelete = (RAMCategory)catSchema.getCategory("Party");
categoryToDelete.delete();
session.put(catSchema, new NullProgressMonitor());

The java doc for the delete method says...
"Marks this category for deletion. The category won't be physically deleted from the repository until RAMSession.commitChanges(IProgressMonitor) or RAMSession.upload(IProgressMonitor) is called."
We are using RAM V7.5.0.2 Build: RAM7502-I20110308_1504 and the API doesn't have the commitChanges() or upload() methods available.

It looks like just calling the session.put(catSchema, new NullProgressMonitor()) method will not delete the category in RAM, how do we accomplish this? Thanks,

Sanjay Karnam

3 answers



permanent link
Rich Kulp (3.6k38) | answered Apr 24 '12, 5:56 p.m.
FORUM MODERATOR / JAZZ DEVELOPER
Sorry,

But it looks like it is broken. There is no code to actually delete a category within a schema.

Rich

permanent link
Sanjay Karnam (4144) | answered Apr 25 '12, 11:27 a.m.
Ok, so do we have to open a PMR with IBM to get around this issue? Or would this code be available in the next releases of RAM?

permanent link
Gili Mendel (1.8k56) | answered Apr 25 '12, 12:05 p.m.
JAZZ DEVELOPER
Yes, it is a bug.

In theory, the session.put(catSchema, new NullProgressMonitor()); should have removed the deleted category, but the the call to .delete() today does not remove the category from the schema immediately, as it should be.

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.