Class XSLTStreamingOutput

  • All Implemented Interfaces:
    javax.ws.rs.core.StreamingOutput

    public class XSLTStreamingOutput
    extends Object
    implements javax.ws.rs.core.StreamingOutput
    This type should be used by resource methods when need to apply XSLT transformation for returned Source.
    Version:
    $Id: XLSTStreamingOutPut.java
    Author:
    Dmytro Katayev
    See Also:
    StreamingOutput
    • Constructor Detail

      • XSLTStreamingOutput

        public XSLTStreamingOutput​(String schemeName,
                                   Source source)
        XSLTStreamingOutput constructor.
        Parameters:
        schemeName - XLST scheme name. Must be registered in TRAXTemplatesLoaderPlugin
        source - entity to write into output stream.
      • XSLTStreamingOutput

        public XSLTStreamingOutput​(String schemeName,
                                   Source source,
                                   Map<String,​String> xsltParams)
        XSLTStreamingOutput constructor.
        Parameters:
        schemeName - XLST scheme name. Must be registered in TRAXTemplatesLoaderPlugin
        source - entity to write into output stream.
        xsltParams - XSLT parameters
    • Method Detail

      • write

        public void write​(OutputStream outStream)
                   throws IOException,
                          javax.ws.rs.WebApplicationException
        .
        Specified by:
        write in interface javax.ws.rs.core.StreamingOutput
        Throws:
        IOException
        javax.ws.rs.WebApplicationException