Specifying a Converter URL

To specify a converter: URL, you need to identify

  • The XML Converter (EDI, CSV, dBase, and so on ) or custom XML conversion definition ( .conv file) you want to use.
  • Options for the XML Converters (separator and escape characters, for example). Options for custom XML conversion are part of the custom XML conversion definition and are not specified.
  • The file to be converted.

Example - Converter URL with a DataDirect XML Converters

A converter: URL that invokes the DataDirect XML Converter for comma-separated values (CSV) to convert the three.txt file in the Stylus Studio\examples directory to XML might look like this:

converter:CSV:newline=lf:first=yes:?file:///c:/StylusStudio/examples/
three.txt
       

    

The instructions to the XML Converters engine from this instance of the converter URL are described the following table.

Instruction
Converter URL String
Use the Comma-Separated Values XML Converter converter
converter:csv
The line separator in the source file is a line feed
newline=lf
The values in the first row of the source file should be used to supply field names
first=yes
The source file is three.txt
file:///c:/StylusStudio/examples/three.txt
Table 24. URL Scheme Example

Properties that use default values (a comma is the default separator character for the CSV XML Converter, for example) do not have to be specified in a converter URL.

Example - Converter URL with a Custom XML Conversion Definition

A converter URL that references a custom XML conversion definition might look like this:

converter:///myConverter.conv?file:inventory.txt
       

    

This converter uses myConverter.conv to convert the file inventory.txt to some format (specified in the custom XML conversion definition when it was built using the Custom XML Conversion Definition Editor in Stylus Studio). Note that individual configuration properties are not specified - they are part of the definition described in the .conv file.

XSL-List

The XSL-List forum is a valuable learning resource for the Extensible Stylesheet Language (XSL), covering the XSL specification, XSL processor implementations, and XSL user questions. Get this free XSL resource delivered to your inbox today.

Stylus Studio Product Documentation

Stylus Studio product documentation consists of The Stylus Studio User's Guide, An online Help system, Release Notes to keep you up to date with Stylus Studio's continuing innovations and enhancements.

Data Integration Tools: Using the Stylus Studio XML Pipeline to Visually Integrate and Publish Data

Data Integration Tools from Stylus Studio include a visual pipeline editor, support for non-XML data sources, scalable data integration components, cross-language debugging and Java code generation. Try it now.

Stylus Most Wanted

 
Free Stylus Studio XML Training:
W3C Member