Configuring Validation Scenarios for a Framework
To associate a validation scenario with a specific framework, follow these steps:
- Open the Preferences dialog box (Options > Preferences) and go to Document Type Association.
- Select the document type and click the Edit button to open the Document Type configuration dialog box, then choose the Validation tab. This tab displays a list of document types in which you can define validation scenarios. To set one or more of the validation scenarios listed in this tab to be used as the default validation scenario (when another one is not specified in the validation process) for a specific document type, check the Default box for that specific document type.
-
To add a new scenario, press the
New button.
The New scenarios dialog box is displayed. It lists all the validation units for the scenario.Figure: Create New Validation Scenario
This scenario configuration dialog box allows you to configure the following information and options:- Name
- The name of the validation scenario.
- Storage
- You can choose between storing the scenario in the Global Options or Project Options.
- URL of the file to validate
- The URL of the main module that includes the current module. It is also the
entry module of the validation process when the current one is validated. To edit
the URL, double-click its cell and
specify the URL of the main module by doing one of the following:
- Enter the URL in the text field or select it from the drop-down list.
- Use the
Browse drop-down button to browse for a local, remote, or
archived file. - Use the
Insert Editor Variable button to insert an editor variable or a custom editor
variable.Figure: Insert an Editor Variable
- File type
- The type of the document that is validated in the current validation unit. Oxygen XML Editor automatically selects the file type depending on the value of the URL of the file to validate field.
- Validation engine
- You can select one of the engines available in Oxygen XML Editor for
validation of the particular document type.
Default engine means that the default engine is used to run the validation for the current document type, as specified in the preferences page for that type of document (for example, XSLT preferences page, XQuery preferences page, XML Schema preferences page).
The DITA Validation engine performs DITA-specific checks in the context of the specifications (it is similar to the checks done with the DITA map
Validate and
Check for Completeness action, but for a local file
rather than an entire DITA map).The Table Layout Validation engine looks for table layout problems (for more information, see Report table layout problems).
- Automatic validation
- If this option is checked, the validation operation defined by this row is also applied by the automatic validation feature. If the Automatic validation feature is disabled in the Document Checking preferences page, then this option is ignored, as the preference setting has a higher priority.
- Schema
- This option becomes active when you set the File type to XML Document and allows you to specify the schema used for the validation unit.
Settings- Opens the Specify Schema dialog box that allows you to set a schema for validating XML documents, or a list of extensions for validating XSL or XQuery documents. You can also set a default phase for validation with a Schematron schema.
Move
Up- Moves the selected scenario up one spot in the list.
Move Down- Moves the selected scenario down one spot in the list.
- Add
- Adds a new validation unit to the list.
- Remove
- Removes an existing validation unit from the list.
- Configure any of the existing validation units according to the information above, and you can use the buttons at the bottom of the table to add, remove, or move validation units. Note that if you add a Schematron validation unit, you can also select the validation phase.
-
Press Ok.
The newly created validation scenario is now included in the list of scenarios in the Validation tab. You can use the Default checkbox to specify that the new scenario be used as the default validation scenario when another specific scenario is not specified in the validation process.