Fork me on GitHub

roxml by Empact

ROXML is a module for binding Ruby classes to XML. It supports custom mapping and bidirectional marshaling between Ruby and XML using annotation-style class methods. ROXML supports the LibXML and REXML XML processors.

We may not want to work with XML, but we don't always get to pick just how our data comes. If you do need to do serious work with XML, ROXML is here to make it nice. Use xpath-based xml declarations to map an XML response into an extensible object, use that object, and then ouput it back to xml as it came. Aside from the basics, ROXML has a lot of little goodies to make these definitions minimal and readable, which are worth digging in for. See the 'xml_convention' method for easily referencing xml which uses other naming conventions. See the handling of '?' in accessor names, the application of blocks and such for other manipulations. And finally, if you use this library, feel free to push code back my way. I'll be looking forward to it.


activesupport >= 2.1.0


'gem install roxml' will install the latest stable rubyforge version


MIT License


Ben Woosley (
Anders Engström (
James Thompson (
James Healy (
Zak Mandhro (
Russ Olsen (


Ben Woosley (


You can download this project in either zip or tar formats.

You can also clone the project with Git by running:

$ git clone git://