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>
没有合适的资源?快使用搜索试试~ 我知道了~
Python自存小项目1.zip
共2000个文件
qml:1390个
png:453个
pyd:410个
需积分: 5 0 下载量 138 浏览量
2022-01-15
15:54:59
上传
评论
收藏 594.84MB ZIP 举报
温馨提示
Python自存小项目
资源详情
资源评论
资源推荐
收起资源包目录
Python自存小项目1.zip (2000个子文件)
Abidjan 148B
Abidjan 148B
Abidjan 141B
Abidjan 141B
Accra 1KB
Accra 1KB
Accra 148B
Accra 148B
Acre 628B
Acre 628B
Acre 189B
Acre 189B
ACT 2KB
ACT 2KB
ACT 185B
ACT 185B
Adak 8KB
Adak 8KB
Adak 2KB
Adak 2KB
Addis_Ababa 265B
Addis_Ababa 265B
Addis_Ababa 184B
Addis_Ababa 184B
Adelaide 8KB
Adelaide 8KB
Adelaide 2KB
Adelaide 2KB
Aden 166B
Aden 166B
Aden 165B
Aden 165B
Alaska 2KB
Alaska 2KB
Alaska 184B
Alaska 184B
Aleutian 2KB
Aleutian 2KB
Aleutian 171B
Aleutian 171B
Algiers 1KB
Algiers 1KB
Algiers 735B
Algiers 735B
Almaty 2KB
Almaty 2KB
Almaty 997B
Almaty 997B
Amman 7KB
Amman 7KB
Amman 2KB
Amman 2KB
Amsterdam 9KB
Amsterdam 9KB
Amsterdam 3KB
Amsterdam 3KB
Anadyr 2KB
Anadyr 2KB
Anadyr 1KB
Anadyr 1KB
Anchorage 8KB
Anchorage 8KB
Anchorage 2KB
Anchorage 2KB
Andorra 7KB
Andorra 7KB
Andorra 2KB
Andorra 2KB
Anguilla 246B
Anguilla 246B
Anguilla 203B
Anguilla 203B
Antananarivo 265B
Antananarivo 265B
Antananarivo 185B
Antananarivo 185B
Antigua 246B
Antigua 246B
Antigua 202B
Antigua 202B
Apia 5KB
Apia 5KB
Apia 612B
Apia 612B
Aqtau 2KB
Aqtau 2KB
Aqtau 983B
Aqtau 983B
Aqtobe 2KB
Aqtobe 2KB
Aqtobe 1011B
Aqtobe 1011B
Araguaina 2KB
Araguaina 2KB
Araguaina 884B
Araguaina 884B
Arizona 328B
Arizona 328B
Arizona 179B
Arizona 179B
共 2000 条
- 1
- 2
- 3
- 4
- 5
- 6
- 20
zhang_zhang_1
- 粉丝: 3
- 资源: 21
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功
评论0