// For comparing responses, need to filter down to a single response area and invoke custom XSL
TransformChain compareChain = new TransformChain(
new FilterElements(),
new XslTransformer(xmlService.findXslResource("compare-responses.xsl")),
new EnsureUniqueWicketIds());
xmlService.registerTransformer("compare-responses", compareChain);
// For viewing single-select response in whiteboard or notebook, need to filter down to a single response area and invoke custom XSL
TransformChain viewChain = new TransformChain(
new FilterElements(),
new XslTransformer(xmlService.findXslResource("view-response.xsl")),
new EnsureUniqueWicketIds());
xmlService.registerTransformer("view-response", viewChain);
// Construct transformation pipeline for student content: glossary -> XSL -> unique wicket:ids
TransformChain transformchain = new TransformChain(
new XslTransformer(xmlService.findXslResource("strip-class.xsl")),
new GlossaryTransformer(glossary),
new FilterElements(),
new XslTransformer(new FileResource(studentXslFile)),
new EnsureUniqueWicketIds());
xmlService.registerTransformer("student", transformchain);
if (emailOn) {
// For sending emails to users
xmlService.loadXSLTransformer("email", getEmailTransformationFile(), true);