The transformer in the code above is initialized with a StreamSource

File template = findFile(pageContext,filename,"xsl");
StreamSource  source = new StreamSource( template );

There is a custom URI resolver which is importing the additional XSL fragments.  I'll see if I can accomplish what you suggest.