| iMatix home page
| << | < | > | >>
GSLgen GSLgen
Version 2.0

Welcome To GSLgen

GSLgen is a general-purpose file generator. It generates source code, data, or other files from an XML file and a schema file. The XML file defines a particular set of data. The schema file tells GSLgen what to do with that data.

GSLgen is based on two powerful concepts. First, we use XML to describe data objects. XML is a modern, clean, and self-describing data description language. Second, we use a general-purpose schema language (GSL) that can be used to do all kinds of manipulation of the XML data and the resulting output. XML + GSL is a strong, yet simple, solution to a problem that is so common that most people don't even realise it exists: producing source code and other text output mechanically, from a set of standard templates (schemas) and object definitions.

The concept of schema-based code generation is extremely powerful and valuable to those who are capable of abstracting a problem. These are some of the things you can do with GSLgen:

  • Generate interfaces between programs. Typically, you define the interface objects as XML, then generate code to pack and unpack these objects. You can use GSLgen to create an ad-hoc generator which will produce code in any language. This is excellent for passing data between components written in different languages, and running on different systems.
  • Generate programs to access a database. We do this a lot: it's enough to define the table we want to work with, then we can generate subroutines to work with that table, SQL scripts to create and maintain it, etc. This is an excellent way to build applications that are portable to any relational database.
  • Generate HTML or other representations of data objects.
  • Converting data between formats. For instance, it's quite common to convert an XML file in one format to another. GSLgen can handle this kind of problem easily.

GSLgen is a portable command-line tool that you can easily integrate into scripts and other tools. GSLgen also comes as a module that you can integrate into your own tools. This is an excellent way to build XML-processing tools and code generators.

iMatix Corporation has released GSLgen as Open Source, so that you can benefit from the power of this tool in your own applications. Prebuilt installation packages are provided for Windows, Linux, and OS/2. You can also build GSLgen from the source code provided.

To use GSLgen, you should be comfortable with the basic concepts of the Extensible Markup Language (XML).

To use GSLgen, you may download and build the package from the source kit. You will need to download the SFL library from imatix.com as well.

There is also an executable available for Windows.

To build GSLgen from the full source kit, download the SFL package, build that, and then run the 'build' command in the gslgen src directory. This creates the gslgen executable and libgsl library for linking with your applications.

If you have questions about using GSLgen, problem reports, or feature requests, please mail gslgen@imatix.com.

| << | < | > | >>
| Welcome To GSLgen
Copyright © 1996-2000 iMatix