XMLMill can be used interactively as follows:
- In a browser through the use of an applet.
- As a Java application.
To use XMLMill in a browser as an applet you need to sign the xmlmill.jar file (and other .jar files needed). Please consult following page to know how to sign jar files: http://java.sun.com/docs/books/tutorial/jar/sign/signing.html.
- XMLMill in a browser has exactly the same functionalities as XMLMill as an application.
XMLMill can run as a standalone Java application using the com.xmlmill.applet.Main class.
The etc/ directory contains the gui.cmd or gui.sh describing the different jar files needed to use XMLMill in different JS2E environments.
- You must add to the classpath the
.jar files representing a JAXP compliant xml-parser and xsl-transformer.
- Check the installation section for more information regarding JAXP.
Following defines the settings needed to start XMLMill with J2SE 1.4 (or higher):
[001]
[002] @echo off
[003] REM --------------
[004] REM XMLMILL GUI
[005] REM --------------
[006]
[007] REM PLEASE CHANGE CLASSPATH TO INCLUDE JAR FILEs CORRECLY.
[008] REM PLEASE CHANGE JAVA_HOME POINTING TO JAVA.EXE.
[009] REM PLEASE CHANGE XMLMILL_HOME POINTING TO JAVA.EXE.
[010]
[011] set JAVA_HOME= "C:\Program Files\Java\j2re1.4.2_07\bin"
[012]
[013] SET XML_HOME=c:\xmlmill30
[014]
[015] set CLASSPATH=%XML_HOME%\lib\xmlmill.jar
[016] set CLASSPATH=%CLASSPATH%;%XML_HOME%\lib\commons-logging-1.1.jar
[017]
[018] %JAVA_HOME%\java com.xmlmill.applet.Main
[019]
- In order to use this batch file you will need to change the
CLASSPATH variable referenced in the batch file to include the mentioned jar files. You also need to change the JAVA_HOME and XMLMILL_HOME variables.
- In case you do not use the default logging mechanism under J2SE 1.4 (or higher) (
java.util.logging. implementation) you'll need to add the .jar file representing the logging mechanism.
In a Windows environment XMLMill can also be started by double-clicking on the xmlmill.jar file on the condition that all necessary jar files are referenced in the meta-inf/Manifest.mf file (using the Class-Path: argument).
The default content of the meta-inf/Manifest.mf file in the xmlmill.jar file is:
[001]
[002] Manifest-Version: 1.0
[003] Ant-Version: Apache Ant 1.6.5
[004] Created-By: 1.3.1_01 (Sun Microsystems Inc.)
[005] Main-Class: com.xmlmill.applet.Main
[006] Class-Path: xercesimpl.jar xalan.jar xml-apis.jar commons-logging-1.1.
[007] jar dom.jar sax.jar jaxp-api.jar
[008]
[009] Name: common
[010] Implementation-Title: xmlmill
[011] Implementation-Version: <version>
[012] Implementation-Vendor: Pecunia Data Systems (http://www.xmlmill.com)
[013] Build-Id: <version> at <date>
- If needed modify the
Class-Path: to incorporate the jar files needed representing your xml-parser and xslt-transformer (this is not needed if you will use the default jars included in the download (contained in the lib/ directory).
- Put all the necessary
jar files in the same directory as the xmlmill.jar file.
If everything is configured correctly, following message is displayed at start-up:
[001] XMLMill Java <version> Use the -? parameter to see
options
A splash screen will be visible while XMLMill is reading the contents of your hard-drive.
Select to enlarge
The following section will explain in detail the user interface
The Graphical User Interface (GUI) is identical for XMLMill used in an applet or as a standalone application.
The GUI contains a topmenu, the Dashboard tab and the Logging tab.
Select to enlarge
Quit the application.
Shows following About screen:
Select to enlarge
The screen contains your:
- License number
- License type
- Licensee
The dashboard tab contains al parameters that can be set to steer the generation process.
The filechooser window is opened and the appropriate .xml or .mill files can be selected.
The filechooser window is opened and the appropriate .xsl file can be selected. Only one .xsl file can be selected. This .xsl file is used to transform the selected .xml files. The selected .xsl file will overrule the .xsl defined in the .xml file using the href attribute in the <?xml-stylesheet ... ?>.
- If
.mill files are selected (using the Open... button) then no .xsl file should be selected.
The filechooser window is opened and the appropriate output directory can be selected. This selection will overrule the outputfolder defined in the .xml or .xsl file (if any)
The filechooser window is opened and the appropriate configuration file can be selected.
The Logging section defines the different options regarding the content of the .log file:
Following loglevels are available:
- TRACE
- DEBUG
- INFO
- WARN
- ERROR
- FATAL
- For more information which level logs which messages please visit the XMLMill Logging chapter.
Select the JAXP version that is appropriate.
Defines when the generation process has to be aborted:
WARN
|
In case a WARNING occurs, the generation process is aborted.
|
ERROR
|
In case a ERROR occurs, the generation process is aborted.
|
FATAL
|
In case a FATAL occurs, the generation process is aborted.
|
- The generation process will always be aborted when a
FATAL error occurs, hence the FATAL button cannot be deselected.
Defines whether the generated intermediate .mill document is validated against the xmlmill.xsd schema.
- Validation will only be done in case the JAXP version is set to
1.3.
When this option is selected a .mill file is generated for each xml/xsl transformation. This file is stored in the output directory. It will have the same name as the xml file but suffixed with a .mill extension. The .mill file can be used to check the transformation output against the xmlmill.dtd or xmlmill.xsd (using a xml editor that can validate a .xml file against a dtd or .xsd).
This option is interesting when you generate a pdf document based on a xml and xsl file. With this option you can inspect what the transformation result is.
Converts the selected .xml or .mill files to PDF. The .pdf files are written in the output directory (if one selected). The name of the .pdf file is defined by the file attribute in the <ml:document> element mentioned in the .xml or .xsl file. The logmessages are shown in the Logging tab during the generation process.
Select to enlarge
If a transformation has successfully ended following information is displayed:
[001] -- Done (xxxxx bytes - xxxx elapsed (milliseconds))
--
The number of bytes written and the elapsed time needed to generate the .pdf document are displayed.
Depending on the .log options choosen other information is also logged.
Resets all fields.
The Logging tab shows during the generation process all logmessages that are generated. This way a 'real-time' follow-up of the generation process is possible.
Select to enlarge
On the bottom two buttons are shown:
Save the generated log messages to a file.
Abort the generation process between generating 2 documents (in case you have selected multiple .xml/.mill documents in the previous tab)..