The plugin.xml controls all aspects of a plug-in, making each extension visible to the rest of the toolkit. The file uses pre-defined extension points to locate changes, and integrates those changes into the core code.
The root element of the plugin.xml file is <plugin>, and must specify an id attribute. The id attribute is used to identify the plugin, as well as to identify whether pre-requisite plugins are available. The id attribute should follow the syntax rules:
id ::= token('.'token)*
token ::= ( [0..9] | [a..zA..Z] | ’_’ | ’-’ )+
The <plugin> element supports the following child elements:
<feature> defines an extension to contribute to a defined extension point. The following attributes are supported:
| Attribute | Description | Required |
|---|---|---|
| extension | extension point identifier | yes |
| value | comma separated string value of the extension | either value or file |
| file | file path value of the extension, relative to plugin.xml | either value or file |
| type | type of the value attribute | no |
<require> defines plug-in dependencies. The following attributes are supported:
| Attribute | Description | Required |
|---|---|---|
| plugin | vertical bar separated list of plug-ins that are required | yes |
| importance | flag whether plug-in is required or optional | no |
<template> defines files that should be treated as templates. The following attributes are supported:
| Attribute | Description | Required |
|---|---|---|
| file | file path to the template, relative to plugin.xml | yes |
<meta> defines metadata. The following attributes are supported:
| Attribute | Description | Required |
|---|---|---|
| type | metadata name | yes |
| value | metadata value | yes |
Any extension that is not recognized by the DITA-OT is ignored; all elements other than <plugin> are optional. Since version 1.5.3 multiple extension definitions within a plugin configuration file are combined; in older versions only the last extension definition is used.