From: paul vudmaska Date: 2003-10-03T02:11:11+09:00 Subject: Re: xml in Ruby >>> -------- From: Erik Terpstra Date: Fri, 3 Oct 2003 00:26:52 +0900 References: 83448 In-reply-to: 83448 Last year I made a quick hack that could do something like that. I didn't have much experience with Ruby back then, so it is a quick and very dirty solution. But the following works: require 'XML' y = XML %{ Joe 28 Engineering Ken 26 Engineering } puts y.employees.employee[0].age y.employees.employee[0].age = '9' puts y.employees.employee[0].age y.employees.employee.each do |employee| puts "name: #{employee.name}, age: #{employee.age}" end ---> for my third cent, the above syntax 'just makes since' to me. What could be more semantic than employee.name without resorting to write your own class/accessors for it? What's wrong with that being a fundamental data acess fascility? call me crazy :pv __________________________________ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com