Quasi-Static and Quasi-Dynamic Constraints

Alexander Schwartzman has written a good article summarizing the lessons learned from using Schematron and DTDs together over multiple years for a non-trivial DTD. JATS Subset and Schematron: Achieving the Right Balance  from the Journal Article Tage Suite Conference 2017 is now online. Alexander is mainly concerned about whether you…

...

Can I assert patterns in Java Objects with Schematron?

Schematron has been useful over the years for detecting patterns in documents.  A simple expert system (multiple if-then-else changes) for capturing the constraints as human language,  implementing the tests using XPaths to provide a context and then to assert or report on things that should be true at the context. …

...

Validation result caching using a keystore

Scenario: You have a messaging or distributed pipeline architecture for your XML documents. An XML document make multiple stopovers from beginning to end, and a document may be stored and requested multiple times in its life.  Your documents go between different operations or groups under your roof, or comes from…

...

Could Schematron be used for Content Completion in editors?

Over at XML.COM,  Gerrit Imsieke has a stimulating article Epischemas: Schema Constraints that facilitate Content Completion.  He wants to improve content completion in XML editors (where the editor automatically fills in the next step) given that many interesting types of documents have additional constraints to those available in a simple…

...

Using Schematron to Test Transformations: Lesson Learned

This decade, I been twice involved in quite intense year-long projects to do exhaustive acceptance testing of XML transformations using Schematron. What lessons did I learn? Projects So the context here is the need for error-free transformations of large numbers of high-value complex documents, where the number of documents and…

...

Schematron and Scrum

How does Schematron fit in with Scrum? This a follow-up to Error Messages and Diagnostics should be Inputs to the Developer not Outputs. According to that, error messages and diagnostics should be provided through the Product Manager as details on the appropriate Product Backlog items. In Scrum terms, you want…

...

Trying out PlantUML with a package diagram for Schematron

PlantUML is a neat tool, quite mature, for generating UML diagrams from text, using a little domain-specific language. It reminds me of UNIX pic, which allowed really fast and easy generation of diagram, up to a point. WYSIWYG really sucks for many technical diagrams: I actively dislike Visio for UML,…

...

Optimizing Schematron using @saxon:memo-function

Tony Graham mentioned in an email his use of Saxon’s optimization hint attribute xsl:function/@saxon:memo-function to memo-ize the values of some functions.  He had investigated it for his Open Source focheck project that checks XSL-FO scripts. I was intrigued as I had never used this technique, and Tony kindly provided details…

...

“Schematron is inefficient”? plus a challenge!

I think the only real complaint I hear sometimes about Schematron is that that some users find it inefficient. I am completely cool with this, in general: Schematron is a general-purpose tool/technology designed to be trivially constructed from COTS components, and the modern world’s answer to inefficiency is usually to…

...

Integrating Schematron with syslog

One of the cool thing about Schematron, is that it allows a high level of integration into systems that might want to consume the results of a validation.  The result of validation is not just the basic valid/invalid distinction (like DTDs), cryptic messages that frustrate end-users, or some abstract and…

...

Six kinds of validation using Schematron

Document Invariants This is the most straightforward use of Schematron: your Schematron script is a schema that states what is supposed to be found  the data, metadata, structures and links in any or every XML document.  These may be fixed  such as “All documents should have head and body sections,…

...

SOA validation logging: reducing first-response latency

XHTML failed as a delivery dialect of HTML because XML is defined so that, strictly, you do not deliver a document until you know it is well-formed. That did not fit in with what WWW users need: they want the parts of the page rendered as soon as possible, as…

...