SPFE Documentation | Collections > SPFE Development > Configuring SPFE Open Toolkit

Configuring SPFE Open Toolkit

Think

The SPFE Open Toolkit (SPFE-OT) must be configured to control how it builds output from source XML markup. One or more configuration files specifies which source content will be processed, how it will be processed, and how it will be organized and linked. Together, the configuration files are the master plan for a SPFE build. SPFE has a distributed configuration model. Every component of the system has a configuration file, and you can assemble your configuration by including the configuration file for the components you use.

SPFE Open Toolkit configuration consists of the following configuration file types:

  1. Content set configuration file: - The top-level configuration file used to build a content set. The content set configuration file specifies the topic sets to be included in the content set and the output formats to be built.

  2. Topic set configuration file: - The configuration for a topic set. It specifies the criteria for including topics in a topic set (generally this is not a fixed list of topics. A topic set configuration file does not have to be updated every time a new topic is created. All the topics that meet the specified criteria are included automatically.) The topic-set configuration file also specifies the topic types that can occur in the topic set and the type of outputs to create for it. (The content set specified specific output configurations for the content set; the topic set configuration specifies which of the available configuration to build for the individual content set.)

  3. Topic type configuration file - The configuration for a topic type. Provides a name for the topic type and specifies the set of structures used in the topic type and the set of scripts used for processing a topic of this type through each of the SPFE processing stages.

  4. Output type configuration file - The configuration of an output type. Specifies the name of the output type and scripts used to build the output. Note that you could configure more than one output type configuration for the same output type. For instance, you could configure two different styles of HTML output. You could then point whichever configuration you wanted to build from the content set configuration file. If both these configurations had the name “html”, topic set configuration files that specified “html” as an output format would not need to change when you built different HTML outputs.

  5. Structure configuration file - The configuration file for a structure. Specifies the scripts to be used for processing a particular structure. Using structures make it easy to configure a topic type by including existing structures. Note that you may want to provide more than one configuration file for a structure, if you want the same structured to be processed differently in different circumstances. While a structure directory will generally include a default structure configuration file, as well as default processing scripts, you are free to create your own structure configuration files for any structure that point to your own processing scripts for that structure. Some EPPO simple structures come with more than one structured configuration file for different purposes.

  6. Presentation type configuration - The configuration file for the presentation stage of the SPFE build. Most topic type and structure configurations will contain the presentation configuration for the presentation types that the author of the topic type or structure was aware of at the time they wrote them. If you wanted to specify a new presentation format for an existing topic type or structure you could do so either by writing entirely new topic type and structure configurations, or by writing a separate presentation type configuration file.

  7. Object type configuration files - The configuration file for an object. Does the same thing for object types that the topic type configuration file does for topic types and the structure configuration file does for structures.

To create a body of content, an author will need to be concerned with the first two, content set and topic set configurations, which identify content sources. Configuring topic types and output formats is not content specific and should be done beforehand by a SPFE Open Toolkit developer.

Plan

Where should the configuration files be located

The content set and topic set configuration files may reside anywhere in the files system that is convenient. References to configuration, source, and other files may be relative or absolute path names. A common setup has the content set configuration file in the working directory, where the spfe command will be executed and log files kept, with topic set configuration files and content files in subdirectories and referenced with relative paths. This way the entire set can be relocated without needing to edit configuration files.

Do

Create a content set configuration XML file in the directory you will execute the spfe command to create builds or any convenient location. Use the /content-set XML structure.

Create a topic set configuration XML file for each topic set using the /topic-set XML structure.

Create a topic type configuration XML file for each topic type using the /topic-type XML structure.

Create a output-format configuration XML file for each output format using the /output-format XML structure.