UPDATE! The community will be go into read-only on April 19, 8am Pacific in preparation for migration on April 21. Read more.
UPDATE! The community will be go into read-only on April 19, 8am Pacific in preparation for migration on April 21.Read more.
Absent Member.
Absent Member.
986 views

get available ChangeRequest.Status from a known status

Hi guys, 

I want to get all available Change Request.Statuses for known status.

For example, one change request in Verified Fixed status, user only can change this status to three statuses: Close, Verified Fixed, Open ,

not the all status from ChangeRequest.Status.ALL.

Are there any api to get this?

Does ChangeRequest use the state machine internally to manage status?

Or i have to list all possible cases in list,  then match the right case.

0 Likes
1 Reply
Micro Focus Expert
Micro Focus Expert

yes, you are asking to follow the workflow of the changerequest.

you need to integrate the workflow class into your application. (see com.starteam.Workflow)

hook the workflow up at the start of your application using the api

/**

* Load the workflow from StarFlow Extensions Once loaded, the rules

* validate state transitions, provide appropriate initialization defaults

* when entering new states, etc. Workflow is stored in StarFlow Extensions

* by default The schema is a folder called "projects" expected to be found

* in the root view of the project called "StarFlow Extensions" Project

* Specific Workflow may be located in sub-folders of "projects" identified

* by project name View specific workflow may be located in sub-folders of a

* specific project identified by view name The workflow is loaded for all

* types that it is available for for this view, it's parent project and the

* server

*

* If the xml is not well formed, or does not conform to the expected

* grammar, an SDK Runtime Exception will be thrown

*

* @param vw

*            the view whose workflow will be loaded for all workflow aware types

*/

public static void Workflow::fromStarFlowExtensions(View vw) {

then you can successfully walk the steps of the workflow, find the current step in the context of an artifact, query its allowed next steps, etc...

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.