Sha256: c2d5ee84e6daf881d8386cbe1c02fa27d23bfd58edaf1a0aa4cbfdeeb1d53ca6
Contents?: true
Size: 1.16 KB
Versions: 1
Compression:
Stored size: 1.16 KB
Contents
ISO Schematron ============== Ruby gem for validating XML against schematron schema Uses [ISO Schematron](http://www.schematron.com) version: 2008-07-28 Installation ------------ % gem install schematron The rubyforge gem is deprecated. [Use gemcutter](http://gemcutter.org/gems/schematron). Command line example ------------------- % stron my_schema.stron my_xml_document.xml Ruby API example ---------------- # overhead require "libxml" require "schematron" include LibXML # load the schematron xml stron_doc = XML::Document.file "/path/to/my_schema.stron" # make a schematron object stron = Schematron::Schema.new stron_doc # load the xml document you wish to validate xml_doc = XML::Document.file "/path/to/my_xml_document.xml" # validate it results = stron.validate xml_doc # print out the results stron.validate(instance_doc).each do |error| puts "#{error[:line]}: #{error[:message]}" end --- Copyright © 2009, [Francesco Lazzarino](mailto:flazzarino@gmail.com). Sponsored by [Florida Center for Library Automation](http://www.fcla.edu). See LICENSE.txt for terms.
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
schematron-0.1.2 | README.md |