Class: Mtk_xslt::XsltProcessor
- Defined in:
- lib/ontomde-core/xslt.rb,
lib/ontomde-core/xslt.rb,
lib/ontomde-core/xslt.rb
Overview
class XsltProcessor < Saxon ; end
Constant Summary
Constants inherited from Xalan
Mtk_xslt::Xalan::TRANSFORMER_FACTORY_IMPL
Instance Method Summary collapse
-
#initialize ⇒ XsltProcessor
constructor
A new instance of XsltProcessor.
- #name ⇒ Object
- #transform(xslt, infile, outfile) ⇒ Object
Constructor Details
#initialize ⇒ XsltProcessor
Returns a new instance of XsltProcessor.
81 82 83 |
# File 'lib/ontomde-core/xslt.rb', line 81 def initialize raise Exception.new("\n***\n***XSLT is not available on your platform. Currently supported platform are JRUBY and Windows\n***\n***") end |
Instance Method Details
#name ⇒ Object
10 11 12 |
# File 'lib/ontomde-core/xslt.rb', line 10 def name return "msxml" end |
#transform(xslt, infile, outfile) ⇒ Object
13 14 15 16 17 18 |
# File 'lib/ontomde-core/xslt.rb', line 13 def transform(xslt,infile,outfile) param="#{infile} -o #{outfile} #{xslt}" cmd="#{File.dirname(__FILE__)}\\converter-ea\\msxsl.exe "+param.tr('/','\\\\') ret=system(cmd) raise Exception.new("\n***\n***Error running command\n***\n***#{cmd}\n***Please check that no msxml process is running in background\n***\n") unless ret end |