You need to load an xml/xsl-processor into your servlet. Most common are SAX or DOM. You have to import the proper package, initialise the processor, load the xml and xsl documents and just pass the output from the processor via out.print to the client.
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com