No release in over 3 years
Low commit activity in last 3 years
A ruby gem that wrappers various schematron implementations so they can be easily used in ruby
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
 Dependencies

Development

~> 1.6
 Project Readme

Schematron-wrapper Build Status

A wrapper around various schematron implementations.

Currently we support: saxon.

Prerequierments

Java should be install in the bin PATH on the target machine.

Usage

# schematron_file - the schematron file content used for validation
# the compilation is time consuming you might consider caching the result
compiled_schematron = Schematron::XSLT2.compile(schematron_file)

# target_xml - a file you will use to validate against
validation_result = Schematron::XSLT2.validate(compiled_schematron, target_xml)

# and finally get the errors
errors = Schematron::XSLT2.get_errors(validation_result)

Check our spec/lib/schematron_spec.rb for a complete example.

Compatibility

Schematron-wrapper is tested against Ruby 2.1.0

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request