Next Previous Contents

4. Processing Phases

4.1 The Startup Phase

After the system is started, xindy reads in the index style that is passed as a command line argument. Each require command is executed and the internal data structures representing the index style are built up. The index style must completely be read in before the raw index can be read.

4.2 The Processing Phase

The processing phase starts with reading the complete raw index. The name of the raw index file must be passed via the command line. All index entries are read in and pre-processed. All attributes and cross reference classes are checked if they are already known to the system. All strings representing location references are matched against all known location classes. Appropriate warnings are issued, if errors are encountered.

After the raw index has completely been read in, the location references of each index entry are merged, separated and sorted and the building of ranges takes place. This phase is the most complex one and we will describe it in detail.

  1. All location references are separated according to the class they belong to. These groups are called location class groups. Possible groups are all defined location and crossref classes. See the commands define-location-class and define-crossref-class for a description how these classes can be defined. The classes are sorted according to an order that can be defined with the command define-location-class-order.
  2. The further processing of each location class group is different for the location classes and the crossref classes.

After all index entries have been processed the letter groups are formed and the index entries and location references are transformed into tree like structures as defined in the index style.

4.3 The Markup Phase

After the index has completely been processed, the markup phase traverses the tree-like structure of the index. Each step triggers the appropriate markup events resulting in the emitting of markup tags. This phase can be traced by using the command line option -t.

Next Previous Contents