I have a system plugin that uses the onContentPrepareForm event to load an xml form fieldset definition into the Joomal CMS Form Object.
FormHelper::addFormPath(JPATH_PLUGINS . '/' . $this->_type . '/' . $this->_name . '/forms');
Using a single definition of the xml file and relative data I can load, display and save the extra information. Then in the past I needed to associate a single Joomla user with multiple versions of my xml form fieldset definition. Loading multiple versions of the data is not a problem (into array) and there are no issues with saving. However I didn't find a way to load multiple definitions of the xml file to display the information so I manually created the form layout of for my xml form definition and then used of foreach to display the same layout multiple times.
Updating the code for Joomla 4/5 I wanted to revisit the code. Is there a way to create multiple versions of the the form field definition as loaded in the plugin, which can then be used to display the multiple sets information from the data array.