Inthe HL7 Adapter, this schematron is useful for validating an HL7 V3 document against
predenedschematron schemas that you write. You can also obtain schemas from
organizationssuch as NHS and HL7.org. For example, NHS provides schemas for CDA
documents.
SchematronConguration in HL7 AdapterYoucongure the schematron validation from the Connectivity Map Properties Editor. The
PropertiesEditor includes two properties to support schematron validation:
■SchematronValidation: Selecting true enables schematron validation. You then need to
enteran LDAP reference.
■SchematronFiles: The list of schematron validation les. Use commas to separate multiple
les.
APIfor Schematron ValidationTheHL7 Adapter includes an API specic to schematron validation. This API is a wrapper of
theOpen source XSLT-based API available at http://xml.ascc.net/schematron/1.5. The
APIis an XSL le called metastylesheet (skeleton1-5.xsl). Applying the metastylesheet to the
schematronXML document generates another XSL le. This XSL le can be applied to the
inputXML document to validate, which produces the output XML document that contains the
resultsof the validation. This document can be embedded inside the V3 acknowledgement and
canbe sent to the original sender.
Themetastylesheet can be extended and overridden so that you can customize the output XML
document.
Example,
Thefollowing is an example of an output document generated after invoking the API using the
XMLinput document and the schematron validation document described above.
<?xml version="1.0"encoding="UTF-8"standalone="yes"?>
<schematron-output phase="#ALL"schemaVersion="" title="" xmlns:
sch="http://www.ascc.net/xml/schematron">
<active-pattern name="Check structure"/>
<fired-rule context="Person"id="" role=""/>
<failed-assert id="" role="" test="@Title"location="/@Person[1]">
<text>The element Person must have a Title attribute</text>
</failed-assert>
<schematron-output>
SunAdapterfor TCP/IP HL7 Overview
SunAdapterfor TCP/IP HL7 User's Guide • Oc tober 200926