Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Policy to create a SubCategory and display that subcategory in the Visual Browse Window

I have to write a custom RAM policy which will do the following:-

User will create a SubCategory and that subCategory should be displayed on the left-hand visual browse window in RAM client.

It is understood that the subCatgory will not be displayed until it has a leaf node under it. But the requirement is that it should be displayed as soon as it is created (after the client refreshes).

When the user creates a "SubCategory Asset", I create the subCategory using the following API.
            matchedCategory= subCategory.createSubCategory(assetObj.getName());

and then I try to categorize assetObj which the "SubCategory Asset" that I just created, with the newly created subCategory.
categorize(assetObj,matchedCategory);

But this gives the following error.

Exception in thread "main" com.ibm.ram.common.data.exception.RAMRuntimeException: Subcategory Business Capability Catalog/Business Capabilities/Move Money & Process Payments/My Buss Cap Asset23 was not found for the asset My Buss Cap Asset23[1.0].
    at com.ibm.ram.client.RAMAsset.categorize(RAMAsset.java:2300)
    at com.cof.custom.policy.CustomPolicyUtility.categorize(CustomPolicyUtility.java:572)
    at com.cof.custom.policy.CustomPolicyUtility.createUpdateSubCategory(CustomPolicyUtility.java:538)
    at com.cof.custom.policy.CustomPolicyUtility.categorizeSubCategoryAssets(CustomPolicyUtility.java:495)
    at com.cof.custom.policy.CustomPolicyUtility.manageAssets(CustomPolicyUtility.java:426)
    at com.cof.custom.policy.CustomPolicyUtility.main(CustomPolicyUtility.java:882)

Will appreciate your help.

Thanks,

Sourav

0 votes


Be the first one to answer this question!

Register or log in 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.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details

Question asked: Feb 15 '13, 3:46 p.m.

Question was seen: 4,306 times

Last updated: Feb 15 '13, 3:46 p.m.

Confirmation Cancel Confirm