XTemplate -- XML Template Engine for Ruby

XTemplate is a package of ruby libraries and programs which formats a XML/HTML document according to a ruby's data structure which consists of Hash and Array. This idea comes from Amrita . So we do not need to explicitly write iterations like for-loop in a template. Such iterations are indicated by an expansion data. We can specify a data ID in XPath like expression, and reconstruct a given data in a template without writing ruby programs. This mechanism provides interoperablity between a template and a ruby script. We can use XML/ YAML documents as an expansion data (See also this page.), since it is automatically converted to a ruby's Hash object.

XTemplate is provided under the term of the modified BSD license .

XTemplate uses one of xmlscan and REXML to parse XML document, so you need to install it. Also, 'xtemplate/yaml.rb' requires YAML4R .


Future requests and questions are allowed to be posted to the "Amrita Users ML". Of course, I will answer to quenstions posted to ruby-talk/ruby-list mailing list.

If you encounter a problem, inform it to me using bug tracking system. Also, feature request tracking system and patch tracking system are available.

Other Resources