Code list validation Architecture
Business rules related to code list validates:

Architecture for Code List validation
The validation of the code lists needs an extra step on the process before executing the Schematron process. This is because it needs Genericode (GC) as input files.
-
The first step is the generation of Genericode (GC) files. These files contains information about the values and identifiers of each code list.
-
GC files are found in the /codelists/gc folder.
-
-
Design and implementation of the CVA files. CVA stands for Context and Value Association:
-
Execution of the implemented validations in the CVA files:
-
Transformation of CVA files into SCH files.
-
Continue with the Schematron execution process: (1) transformation of SCH files into XSLT and execution of the validations using the XSLT files to get the final report.
-

What does the SCH file contain?
-
Association between one or more elements of the XML and one or more code list (specified in the Genericodes).
-
The declaration of which attributes of the XML identify information of the Genericode.
The implementation of the CVA file has the following structure:

Execution
As a basis of the implementation, it has been taken into account:
-
Schematron implementation of CVA files for validation from CRANE SOFTWRIGHTS LTD

This example describes the execution of the validation process using the Saxon library to execute XSLT files and the XSLT provided as a basis:
