A
document type or
framework is associated to an
XML file according to a set of rules. It includes also many settings that improve editing in
the Author mode for the category of XML files it applies for. These settings include:
- a default grammar used for validation and content completion in both Author mode and
Text mode;
- CSS stylesheet(s) for rendering XML documents in Author mode;
- user actions invoked from toolbar or menu in Author mode;
- predefined scenarios used for transformation of the class of XML documents defined by
the document type;
- XML catalogs;
- directories with file templates;
- user-defined extensions for customizing the interaction with the content author in
Author mode.
To open the Document Type Association preferences page go to .
Oxygen XML Editor plugin is highly customizable. Practically you can
associate an entire class of documents (grouped logically by some common features like
namespace, root element name or filename) to a bundle consisting of CSS stylesheets,
validation schemas, catalog files, new files templates, transformation scenarios and even
custom actions. The bundle is called document type and the association is called
Document Type Association or, more generically, framework.
The following actions are available in this preferences panel:
- Change framework directory location - specifies a custom frameworks
folder
from where Oxygen XML Editor plugin
loads the document types;
- Document types table - presents the currently defined document type
associations, ordered by priority and alphabetically. Each row of the table represents a
document type association, each holding the following information:
- Document type - name of the document type;
- Enabled - when checked, the corresponding document type
association is enabled and analyzed when the application is trying to determine the type
of an opened document;
-
Storage - displays the type of
location where the framework configuration file is stored. Can be one of
External (framework configuration is saved in a file) or
Internal (framework configuration is stored in the
application's internal options);
Note: Note that if you set the
Storage to Internal and the document
type association settings are already stored in a framework file, the file content
is saved in application's internal options and the file is removed.
- Priority - depending on the
priority level, Oxygen XML Editor plugin establishes the order in which the existing
document type associations are evaluated to determine the type of a document you are
opening. It can be one of the following: Lowest,
Low, Normal, High,
Highest. You can set a higher priority to Document Type
Associations you want to be evaluated first;
When expanding a Document Type Association its defined rules are
presented. A rule is described by:
- Namespace - specifies the namespace of the root element from
the association rules set (* (any) by default). If you want to apply the rule
only when the root element is in no namespace, leave this field empty (remove the
ANY_VALUE string);
- Root local name - specifies the local name of the root element
(* (any) by default);
- File name - specifies the name of the file (* (any) by
default);
- Public ID - represents the Public ID of the matched
document;
- Java class - presents the name of the Java class which is used
to determine if a document matches the rule;
- New - opens a dialog box that allows you to add a new
association;
- Edit - opens a new dialog allowing you to edit an existing
association;
Note: If you try to edit an existing association type when you have no write
permissions to its store location, a dialog box will be shown, asking if you want to
duplicate the document type.
- Delete - deletes the selected associations;
- Enable DTD/XML Schema processing in document type detection - when
this option is enabled, the matching process also examines the DTD/XML Schema associated
with the document. For example, the fixed attributes declared in the DTD for the root
element are also analyzed, if this is specified in the association rules.
This is
especially useful if you are writing DITA customizations. DITA topics and maps are also
matched by looking for the DITAArchVersion attribute of the root element.
This attribute is specified as default in the DTD and it is detected in
the root element, helping Oxygen XML Editor plugin to correctly match the DITA
customization.
This option is enabled by default;
- Only for local DTD's / XML Schemas - when the previous feature is
enabled, you can choose with this option to process only the local DTD's / XML
Schemas.
This option is enabled by default.