ISO SCHEMATRON 2010
XSLT implementation by Rick Jelliffe with assistance from members of Schematron-love-in maillist.
2010-04-21
Two distributions are available. One is for XSLT1 engines.
The other is for XSLT2 engines, such as SAXON 9.
This version of Schematron splits the process into a pipeline of several different XSLT stages.
1) First, preprocess your Schematron schema with iso_dsdl_include.xsl.
This is a macro processor to assemble the schema from various parts.
If your schema is not in separate parts, you can skip this stage.
This stage also generates error messages for some common XPath syntax problems.
2) Second, preprocess the output from stage 1 with iso_abstract_expand.xsl.
This is a macro processor to convert abstract patterns to real patterns.
If your schema does not use abstract patterns, you can skip this
stage.
3) Third, compile the Schematron schema into an XSLT script.
This will typically use iso_svrl_for_xslt1.xsl or iso_svrl_for_xslt2.xsl
(which in turn invoke iso_schematron_skeleton_for_xslt1.xsl or iso_schematron_skeleton_for_saxon.xsl)
However, other "meta-stylesheets" are also in common use; the principle of operation is the same.
If your schema uses Schematron phases, supply these as command line/invocation parameters
to this process.
4) Fourth, run the script generated by stage 3 against the document being validated.
If you are using the SVRL script, then the output of validation will be an XML document.
If your schema uses Schematron parameters, supply these as command line/invocation parameters
to this process.
The XSLT2 distribution also features several next generation features,
such as validating multiple documents. See the source code for details.
Schematron assertions can be written in any language, of course; the file
sch-messages-en.xhtml contains the diagnostics messages from the XSLT2 skeleton
in English, and this can be used as template to localize the skeleton's
error messages. Note that typically programming errors in Schematron are XPath
errors, which requires localized messages from the XSLT engine.
ANT
---
To give an example of how to process a document, here is a sample ANT task.
<target name="schematron-compile-test" >
<!-- expand inclusions -->
<xslt basedir="test/schematron"
style="iso_dsdl_include.xsl" in="test.sch" out="test1.sch">
<classpath>
<pathelement location="${lib.dir}/saxon9.jar"/>
</classpath>
</xslt>
<!-- expand abstract patterns -->
<xslt basedir="test/schematron"
style="iso_abstract_expand.xsl" in="test1.sch" out="test2.sch">
<classpath>
<pathelement location="${lib.dir}/saxon9.jar"/>
</classpath>
</xslt>
<!-- compile it -->
<xslt basedir="test/schematron"
style="iso_svrl_for_xslt2.xsl" in="test2.sch" out="test.xsl">
<classpath>
<pathelement location="${lib.dir}/saxon9.jar"/>
</classpath>
</xslt>
<!-- validate -->
<xslt basedir="test/schematron"
style="test.xsl" in="instance.xml" out="instance.svrlt">
<classpath>
<pathelement location="${lib.dir}/saxon9.jar"/>
</classpath>
</xslt>
</target>
Unconquerablep
- 粉丝: 81
- 资源: 11
最新资源
- 基于数值积分和摄动方法的建筑装饰金箔使用量计算-Mathematica
- matlab:双或三方演化博弈,lotka-Volterra 1.双方演化博弈:代分析稳定点分析,代绘制相位图,matlab仿真图代码 2.三方演化博弈:代分析稳定点分析,代绘制相位图,matlab仿
- 基于模型预测控制(mpc)的车辆道,车辆轨迹跟踪,道轨迹为五次多项式,matlab与carsim联防控制
- SQL Server数据库实验:表的插入、修改和删除操作实践
- 2011-2020年各省城镇单位就业人员数据.xlsx
- Java windows GUI 案例 简单的飞机售票系统 课程设计
- 基于模型预测控制的楼宇负荷需求响应研究 参考文档:《Model Predictive Control of Thermal Storage for Demand Response》完全复现 主要内容:
- eclipse-sts-2021-03-R-win32-x86-64.rar
- Python的Mongodb操作代码
- 光伏电池PV建模,基于Boost Buck电路实现最大功率追踪MPPT,包括扰动观察法,电导增量法,改进型电导增量法,滑模变结构法等控制算法,模型仿真效果较好,适合借鉴学习 图片为模型图,功率波形
- 交直流混合微网程序matlab 采用拉丁超立方抽样和多场景缩减,考虑风光等随机性建模,利用粒子群算法,计算得到三个微网的优化程序,程序运行稳定,有详细资料 这段代码是一个多目标优化算法的实现,主要用
- 云链客服需要注意的事项
- Microsoft Edge111
- 云链客服需要注意的事项
- 三相桥式两电平逆变器的SVPWM调制和三相T型三电平逆变器的SVPWM模型和说明文档 对比着看绝对有助于你理解SVPWM调制方法 支持MATLAB2017b以上的版本
- mongodb-windows-x86-64-7.0.15-signed.msi
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈