private static Transformer transformer ( final TransformerFactory factory , final Source stylesheet ) throws TransformerConfigurationException { final Transformer tnfr = factory . newTransformer ( stylesheet ) ; if ( tnfr == null ) { throw new TransformerConfigurationException ( String . format ( "%s failed to create new XSL transformer for '%s'" , factory . getClass ( ) , stylesheet . getSystemId ( ) ) ) ; } return tnfr ; }
Make a transformer from this stylesheet .