com.reverseXSL
Class Transform

java.lang.Object
  extended by com.reverseXSL.Transform

public class Transform
extends java.lang.Object

Transformation command-line tool.

You can customize source code (available in the jar) and make your own 'TransformPlus' version.

This tool is a command-line wrapping of the original Transformer API.

Simplest use, with a single jar containing software and transformation meta-data:
(meta-data comprises Parsing DEFinitions, XSL templates, and the mapping selection table)

  java -jar ReverseXSL.jar myInputDataFile

variant (assuming ReverseXSL.jar on the CLASSPATH):
(picking-up resources from directories and/or multiple jar's using the CLASSPATH)

  java com.reverseXSL.Transform myInputDataFile

both these command lines followed by ... >MyOutputFile
do capture the transformed result to a file; indeed, output is written on stdout whereas execution logs are written on stderr

Advanced use (assuming ReverseXSL.jar on the CLASSPATH):

  java com.reverseXSL.Transform myDEFFile myXSLFile myInputDataFile

where the parser DEF file and the XSL template file instruct to, respectively, parse the input with the associated Parsing DEFinition, and then transform the resulting XML with the specified XSL template. If any of those two resources are not found relative to the current working directory, the corresponding transformation step is omitted.

Tip: simply use placeholder DEF or XSL arguments like 'NoDEF' and 'NoXSL' to skip the corresponding transformation step.

Note that optional command-line arguments are noted below within '[' ']', possibly nested.

  java com.reverseXSL.Transform myDefinitionFile myXSLFile myInputDataFile [<InputCleansing> <MaxFatalExceptions> <MaxExceptions> [<true|false> [<indent>] ] ]

or yet:

  java com.reverseXSL.Transform AUTO SELECT myInputDataFile [<InputCleansing> <MaxFatalExceptions> <MaxExceptions> [<true|false> [<indent>] ] ]

In which case a mapping_selection_table.txt (fixed name) file is searched up in the directory hierarchy such as to dynamically resolve which parsing DEF and/or XSL template to apply to the given input data.

/!\ Note that the output is written on stdout whereas execution messages and logs are written on stderr; the transformed output is thus captured using command-line output redirection. For instance:

  java -jar ReverseXSL.jar myInputDataFile >myOutputFile

Please refer to the Software Manual for an overview and tutorial samples.


Constructor Summary
Transform()
           
 
Method Summary
static void main(java.lang.String[] args)
          Entry to the command-line tool for 'reverse-XSL' data transformations.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Transform

public Transform()
Method Detail

main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception
Entry to the command-line tool for 'reverse-XSL' data transformations.

Parameters:
args - command line arguments as described in Transform
Throws:
java.lang.Exception