ealet
Class HTMLer

java.lang.Object
  extended by ealet.HTMLer

public class HTMLer
extends java.lang.Object

The transformation from XML to HTML is performed by this class. It requires an XML source and XSL source.

XSLT 2.0 does allows multiple files transformation from one style, but as this of writing JAXP doesn't support XSLT 2.0; therefore, in order to produce multiple files with content variation, parameters are used.


Constructor Summary
HTMLer()
           
 
Method Summary
 void readStyle(java.io.File xslFile)
          Reads an XSL file and stores the contents into an instance of StringBuffer.
 java.lang.String transformMonthly(java.lang.String xslFileName, java.lang.String xmlFileName, java.lang.String month)
          It ransforms the given XML file based on the XSL style to a StringWriter object, then returns the result in a String form.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HTMLer

public HTMLer()
Method Detail

readStyle

public void readStyle(java.io.File xslFile)
Reads an XSL file and stores the contents into an instance of StringBuffer.

Parameters:
xslFile - Afile object representing the XSL file
Since:
2.0

transformMonthly

public java.lang.String transformMonthly(java.lang.String xslFileName,
                                         java.lang.String xmlFileName,
                                         java.lang.String month)
It ransforms the given XML file based on the XSL style to a StringWriter object, then returns the result in a String form. The transformation is done on monthly basis.

Parameters:
xslFileName - style file for transformation
xmlFileName - a document to be transformed to HTML
month - criteria
Returns:
The document in HTML form
Since:
2.0