Sfairadora

  • Reference Guide

create_unique_name

create_unique_name(struct_type, name)
The struct_type parameter must be a type of the structure category. The name parameter of the type String is a candidate for a new component name. If the name parameter is not a name of any component of the type struct_type, the function returns the name unmodified. If, however, an item of the specified name already exists in the structure, the function appends a number at the end of the name, so that the name is unique within the structure. This modified value is then returned as the result (the value of the name parameter itself is retained unchanged.) If the struct_type parameter is not a structure, the value of the name parameter is always returned unchanged.