State change of an asset using API
9 answers
To find the available actions for a given state use..
To invoke an action on an asset use
For more code example refer to the help system...
http://publib.boulder.ibm.com/infocenter/ramhelp/v7r5m0/topic/com.ibm.ram.doc/topics/t_using_api.html
//Get the available lifecycle actions
RAMAction[] actions = newAsset.getAvailableActions();
To invoke an action on an asset use
//Set the lifecycle action
newAsset.setAction(action);
session.put(newAsset, new NullProgressMonitor());
For more code example refer to the help system...
http://publib.boulder.ibm.com/infocenter/ramhelp/v7r5m0/topic/com.ibm.ram.doc/topics/t_using_api.html
I am trying to change the state of assets using API i.e. I want them to move from Submitted to Appproved, is there any standard RAM API available that would do this activity in a single go.
Thanks, but this was not my question, this would allow me different actions on the asset like UPDATE, DELETE etc. but thats not what I need, in RAM when an asset is submitted it remains in the submitted state and I want to change the state to Approved. How can I achieve that?
To find the available actions for a given state use..
//Get the available lifecycle actions
RAMAction[] actions = newAsset.getAvailableActions();
To invoke an action on an asset use
//Set the lifecycle action
newAsset.setAction(action);
session.put(newAsset, new NullProgressMonitor());
For more code example refer to the help system...
http://publib.boulder.ibm.com/infocenter/ramhelp/v7r5m0/topic/com.ibm.ram.doc/topics/t_using_api.html
I am trying to change the state of assets using API i.e. I want them to move from Submitted to Appproved, is there any standard RAM API available that would do this activity in a single go.
Also it seems the RAMStateHistory API is available in RAM 7.5 and up, but I am using RAM 7.2 so is there any ready way so that I can update the status of an asset through API?
To find the available actions for a given state use..
//Get the available lifecycle actions
RAMAction[] actions = newAsset.getAvailableActions();
To invoke an action on an asset use
//Set the lifecycle action
newAsset.setAction(action);
session.put(newAsset, new NullProgressMonitor());
For more code example refer to the help system...
http://publib.boulder.ibm.com/infocenter/ramhelp/v7r5m0/topic/com.ibm.ram.doc/topics/t_using_api.html
I am trying to change the state of assets using API i.e. I want them to move from Submitted to Appproved, is there any standard RAM API available that would do this activity in a single go.
The StateHistory API was added in 7.2.0.2. So if you go upto that fix pack you can use the API.
Also it seems the RAMStateHistory API is available in RAM 7.5 and up, but I am using RAM 7.2 so is there any ready way so that I can update the status of an asset through API?
To find the available actions for a given state use..
//Get the available lifecycle actions
RAMAction[] actions = newAsset.getAvailableActions();
To invoke an action on an asset use
//Set the lifecycle action
newAsset.setAction(action);
session.put(newAsset, new NullProgressMonitor());
For more code example refer to the help system...
http://publib.boulder.ibm.com/infocenter/ramhelp/v7r5m0/topic/com.ibm.ram.doc/topics/t_using_api.html
I am trying to change the state of assets using API i.e. I want them to move from Submitted to Appproved, is there any standard RAM API available that would do this activity in a single go.
Doing an action is how you change the state. For example the default
simple lifecycle uses the "Publish" action to go from Submitted to Approved.
To invoke an action on an asset use
--
Rich Kulp
Rational Asset Manager developer
simple lifecycle uses the "Publish" action to go from Submitted to Approved.
To invoke an action on an asset use
//Set the lifecycle action
newAsset.setAction(action);
session.put(newAsset, new NullProgressMonitor());
--
Rich Kulp
Rational Asset Manager developer
Thanks Rich,
I am using RAM 7.2.0.1 and the options that come when I try newAsset.setAction are ARCHIVE, CREATE, CREATE_AS_IS, DELETE, RETIRE, UPDATE, UPDATE_AS_IS. I dont see any option of Publish. Is there any thing wrong in what I am trying?
I am using RAM 7.2.0.1 and the options that come when I try newAsset.setAction are ARCHIVE, CREATE, CREATE_AS_IS, DELETE, RETIRE, UPDATE, UPDATE_AS_IS. I dont see any option of Publish. Is there any thing wrong in what I am trying?
Doing an action is how you change the state. For example the default
simple lifecycle uses the "Publish" action to go from Submitted to Approved.
To invoke an action on an asset use
//Set the lifecycle action
newAsset.setAction(action);
session.put(newAsset, new NullProgressMonitor());
--
Rich Kulp
Rational Asset Manager developer
Since the lifecycles are now customizable there are no statics for the actions between lifecycles. We have added API to get the available actions from a RAMAsset. From this you can choose the action that corresponding with publish.
However I beleve this API was added in 7.2.0.2. You should consider moving up.
However I beleve this API was added in 7.2.0.2. You should consider moving up.
Thanks Rich,
I am using RAM 7.2.0.1 and the options that come when I try newAsset.setAction are ARCHIVE, CREATE, CREATE_AS_IS, DELETE, RETIRE, UPDATE, UPDATE_AS_IS. I dont see any option of Publish. Is there any thing wrong in what I am trying?
Doing an action is how you change the state. For example the default
simple lifecycle uses the "Publish" action to go from Submitted to Approved.
To invoke an action on an asset use
//Set the lifecycle action
newAsset.setAction(action);
session.put(newAsset, new NullProgressMonitor());
--
Rich Kulp
Rational Asset Manager developer
Ok in that case can you please tell me how I can apply the fix packs so that this activity can be carried out.Is there any documentation available to apply the fix packs?
Since the lifecycles are now customizable there are no statics for the actions between lifecycles. We have added API to get the available actions from a RAMAsset. From this you can choose the action that corresponding with publish.
However I beleve this API was added in 7.2.0.2. You should consider moving up.
Thanks Rich,
I am using RAM 7.2.0.1 and the options that come when I try newAsset.setAction are ARCHIVE, CREATE, CREATE_AS_IS, DELETE, RETIRE, UPDATE, UPDATE_AS_IS. I dont see any option of Publish. Is there any thing wrong in what I am trying?
Doing an action is how you change the state. For example the default
simple lifecycle uses the "Publish" action to go from Submitted to Approved.
To invoke an action on an asset use
//Set the lifecycle action
newAsset.setAction(action);
session.put(newAsset, new NullProgressMonitor());
--
Rich Kulp
Rational Asset Manager developer