Utility Functions : List of Utility Functions : stm_list_sort_by_chart

stm_list_sort_by_chart
Alphabetically sorts the input list of named Rational Statemate elements, by the name of the chart to which they belong. The input list consists of Rational Statemate elements.
This function receives and returns a list of element IDs, not a list of element names.
Function Type
stm_list
Syntax
stm_list_sort_by_chart (el_list, &status)
Arguments
Input/Output
Status Codes
Example
To sort a list of items by the chart they belong to, use the following statements:

 

stm_list st_list, sorted_by_chart
int status;
.
.
st_list = stm_r_st_name_of_st ("*", &status);
sorted_by_chart = stm_list_sort_by_chart (st_list,&status);

A list of all named statuses is retrieved, then the sort function orders the list by chart name.