|
Home > Online Product Documentation > Table of Contents > Example - demo.java Example - demo.java
The example file,
Demonstration Files
The files required to run the demonstrations are summarized in
Table 149. All but one,
Running demo.javaTo start the demo.java demonstration:
1. Open a console window.
2. Change to the
examples\Adapters directory where you installed Stylus Studio.
3. Run
demo.bat (or
demo.sh, if you installed the Stylus Studio XML Deployment Components on a Unix machine).
Required Classes
In addition to standard Java classes like
The
Setting the Installation Directory
The
You can also specify the Stylus Studio installation directory manually, using the
Example 1
Example 1 converts a comma-separated values (CSV) file,
Both input and output streams are opened and closed by the
Example 2Example 2 is similar to Example 1, but instead of converting a non-XML file to XML, it does the opposite. It also shows how to use the Stylus Studio URI resolver to create both the input stream (sff.resolve("two.xml", uriBase)) and output stream (sff.outputStreamResolver("two.csv", uriBase)).
In this example, since we opened the input and output streams, we must also close them.
Example 3
Example 3 uses a user-defined converter,
Example 4Examples 1, 2, and 3 performed simple conversion of one file type to another - some type of converter (either a Stylus Studio built-in adapter or a user-defined converter) was given an input and converted it to another format.
Example 4 generates conversion output (in this case, a CSV file,
Here is the code for Example 4:
The
Example 5
In Example 5, output from an XSLT transformation is sent to a converter, which takes the XML it is given (as a
Here is the code for Example 5:
As with Example 4, no XSLT transformation instructions were specified (
|
Building Workflow Applications with XML
Learn how to design custom XML workflow applications - from modeling your data and information processes, to capturing input from users in XML, and finally, generating useful queries and reports from the XML data -- using XSLT & XQuery technologies.
Consumer Food Products
Want to know what special ingredient is in these consumer food product companies work enviornment? Well it's a touch Stylus Studio that give these consumer food product companies the extra edge they need for producing such high quality food products!
XML Schema Validator, DTD Validator
Stylus Studio lets you validate XML documents using integrated XML Schema or DTD validators. Use the Stylus Studio built-in validator, or any number of supported XML parsers and XML validators like MSXML SAX and DOM, Xerces, .NET, and more!
XML Parser
An XML Parser is a parser that is designed to read XML and create a way for programs to use XML. Learn about Stylus Studio's comprehensive support for all of the world's leading XML Parsers.


