com.tyenki.tree
Class TreePreprocessor

java.lang.Object
  extended by com.tyenki.tree.TreePreprocessor

public class TreePreprocessor
extends Object

This class produces an XSLT-based tree generator corresponding to the specified configuration.

Version:
18 February 2009
Author:
Christophe Lauret

Constructor Summary
TreePreprocessor()
          Creates a new pre-processor using the default resource locator.
TreePreprocessor(ResourceLocator locator)
          Creates a new pre-processor.
 
Method Summary
 Templates compile(File config, TreeFormat format)
          Process the XML configuration file and returns the corresponding XSLT templates.
 Templates compile(Source config, TreeFormat format)
          Process the XML configuration file and returns the corresponding XSLT templates.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TreePreprocessor

public TreePreprocessor()
Creates a new pre-processor using the default resource locator.


TreePreprocessor

public TreePreprocessor(ResourceLocator locator)
Creates a new pre-processor.

Parameters:
locator - The resource locator to find pre-processors.
Method Detail

compile

public Templates compile(File config,
                         TreeFormat format)
                  throws TreeException,
                         FileNotFoundException
Process the XML configuration file and returns the corresponding XSLT templates.

Parameters:
config - The configuration file.
format - The tree format the processor should generate.
Returns:
The corresponding XSLT template instances.
Throws:
TreeException - Should an error occur while compile the tree.
NullPointerException - if the configuration or format is null.
FileNotFoundException

compile

public Templates compile(Source config,
                         TreeFormat format)
                  throws TreeException
Process the XML configuration file and returns the corresponding XSLT templates.

Parameters:
config - The configuration files.
format - The tree format the processor should generate.
Returns:
The corresponding XSLT template instances.
Throws:
TreeException