in reply to Re^4: XML::Twig Stream root children
in thread XML::Twig Stream root children

I may be overlooking something here. The generated "split files" would consist of the 'a' or 'aa', or whatever other level 1 element. So correct me if I'm wrong, but the only thing missing would be the '<root>' first line and '</root>' last line, right? Adding those to each of the files is left as an exercise to the reader.