import javax.xml.transform.*; import javax.xml.transform.stream.*; import java.io.*; public class xml2html { public static void main(String[] args) throws TransformerException, TransformerConfigurationException, FileNotFoundException, IOException { TransformerFactory tFactory = TransformerFactory.newInstance(); Transformer transformer = tFactory.newTransformer(new StreamSource("stocks.xsl")); transformer.transform(new StreamSource(args[0]), new StreamResult(new FileOutputStream(args[1]))); System.out.println("** The output is written in "+ args[1]+" **"); } }